How to stop blogger shortcodes from working in PRE tags?


We all know about the great development of Blogger Shortcodes by @Mohammad, many of must be already using the shortcodes on their blogger blog. From this platform I again want to thank Mohammad for the revolutionary develpoment.

These days I’m also publishing tutorials for Blogger Shortcodes on my blog, like YouTube Polugin Shortcode, facebook Page Plugin Shortcode and many more. Also I have integrated Blogger Shortcodes in my blog. So the problem which I’m facing is that when in tutorials I have to put some shortcodes for giving examples they don’t appear as text, they just automatically are converted into plugins, like Facrbook Page Widget or YouTube Player or any Message Box. Even inside PRE Tags codes don’t appear. So I want to ask everybody is there any way to stop some specific blogger shortcodes from working in some specific part of the blog like posts.

Also at this time if we integrate Blogger Shortcodes to our blog then all the included plugins are automatically added because their sscripts are present in the Dynamically updated JS file, which is provided by MBT, and is must to be addded to blog, to integrate Blogger Shortcodes.

So I request @Mohammad for creating a facility, so that we’ll get freedom to add any specific Blogger Shortcode to our blogs rather than adding all of them.

Like on my blog I have nothing to do with YouTube Plugin, I just want to have Message Box Shortcodes on my Blog. So there should be way by which I can only integrate the Message Box Blogger Shortcodes to my blog.

Hope you’ll understand.


Thank you for that detailed question dear @NamanKumar. And I would love to answer it in parts

  1. The only possible way to stop rendering Shortcodes on your blogs is to edit the Functions for each shortcode. For example the Function handler will parse [accordion] to the accordion widget but if you edit the Accordion function and rename it as Myaccordion then the Function handler will only display the widget when you type [Myaccordion] and not when you type [accordion]. In short make your function names different from the standard shortcode names in order to be able to share the standard shortcodes as text with your readers.
  • You can do this by copying the code from dynamically updated JS file and pasting it directly on your template and then editing the function names inside the global contant and the shortcode function. Two places only
  1. The method above will also give you the option of keeping the shortcode functions that you wish to use and removing the rest.

Hope this answers your question :innocent: