[Resolved] How to filter( and render ) a perticular shortcode only ?
what’s needed ::
$content = “some text [code]
[/code] some other text[button3] here”;
I want to filter only [code] shortcode. Hooks for buttons and code are already registered. So when I call do_shortcode( $content ); both [code] and [button3] are filtered but i do not want shortcode other than [code] to get filtered. And also I cannot unregister any shortcode.
I think do_shortcode_tag() or regular expression will come handy to find all [code][/code] tags and then filter them using preg_replace_callback, but i am not able to form correct regular expression. I also do not know how to use do_shortcode_tag to filter only [code][/code] shortcode.
please help !!
- The topic ‘[Resolved] How to filter( and render ) a perticular shortcode only ?’ is closed to new replies.