fazarcon

portable shortcode

Jun 14th, 2022
24
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.18 KB | None | 0 0
  1. function your_shortcode($atts, $content = null) {
  2. ob_start();
  3. do_action('hook_name');
  4. return ob_get_clean();
  5. }
  6. add_shortcode('portable_hook', 'your_shortcode');
Advertisement
Add Comment
Please, Sign In to add comment