Advertisement
fahimmurshed

Limit WooCommerce Description and Short Description

Dec 4th, 2022
835
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.19 KB | None | 0 0
  1. add_filter('woocommerce_short_description','limit_short_descr');
  2.  
  3. function limit_short_descr($description){
  4.   return ($description > 140) ? substr($description, 0 , 140) : $description;
  5. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement