daily pastebin goal

Custom Category Placeholder (parsing other shortcodes)

eventsmanager Oct 3rd, 2018 83 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. add_filter('em_category_output_placeholder','my_em_placeholder_mod',1,3);
  2. function my_em_placeholder_mod($replace, $EM_Category, $result){
  3.     switch( $result ){
  4.     case '#_CATEGORYDESCRIPTION':
  5.         $replace = do_shortcode($EM_Category->description);
  6.         break;
  7.     }
  9.     return $replace;
  10. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand