1
votes

I created a website and used custom shortcodes, created within my functions file.

I've updated the site a few times now without thinking about what effect it may have on the shortcodes. Now I want to add to the shortcodes I already had but of course I can't find the orginal shortcodes as the updates overwrote the functions file.

So why is it my shortcodes still function? Does wordpress make a back up and its calling the shortcodes from this older version, if so where can I find it?

If theres a way to access the code that these shortcodes still seem to be using it would save me a lot of time trying to recreate the old code.

If I can find them, I've learnt my lession and will store the shortcodes within their own page so they won't be overwritten again.

Regards Ben

1
McNab, thank you. It'd been a while since I touched the website. I didn't think there was a functions file within my theme, but I just looked and there it was with all my shortcodes. You've just saved me a lot of work and time, Thanks you if you want to repost I'll mark your reply as the answer :D - lil_bugga
Will do, excellent stuff! - McNab

1 Answers

0
votes

Wordpress updates don't affect the wp-content directory so your theme's functions.php file won't have been touched by a Wordpress upgrade and all shortcodes will still function.

The exception to that would be if they rely on core functions which become deprecated in the Wordpress upgrade - but this doesn't seem to be the case for you.