1

So I am trying to change the theme of my WordPress blog. I have visual composer installed. When I try to change the theme, the featured images for the posts show up fine but the in post images are getting replaced by shortcodes like this [thb_image image="1124"][thb_gap height="20"]. What do I need to do to get the images back?

1 Answers1

3

I'm unfamiliar with the thb_image shortcode, but it sounds like they are registered inside your old theme, which would explain why they are no longer working when you change themes.

Dig through your old theme files and search for add_shortcode. You'll need to find the appropriate ones (thb_image and thb_gap) and copy them to your current theme's functions.php file.

Alternatively, I would wager the image="1234" is the ID of the image, and you can just find that in your media library and stick it in the page content using the visual editor.

Xhynk
  • 13,513
  • 8
  • 32
  • 69
  • So I did search through the old theme, I have files like thb_image.php and thb_gap.php etc in a sub-folder and they have been used in a file named "visualcomposer-extend.php". So what exactly am I supposed to copy in my functions.php? – Harsh Butani Jun 23 '18 at 05:40
  • Well you'll need to copy all of the code from in them, and based on what's in them, perhaps even the code the calls those two files. – Xhynk Jun 23 '18 at 17:40