MyBB Community Forums

Full Version: Replace template
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello!

I have problem, when I use find_replace_templatesets it replace all the template and leave it blank.

What is the problem?

Thanks!
What's the code you are using?
find_replace_templatesets("showthread", "#".preg_quote('XXXX')."#i", 'XXXX');
That's really strange.
It clears all the templates? In every templateset?
You are running this code in the _activate() function?
Does it also happen on a fresh MyBB install?
It replace the whole showthread template.
The code you posted wouldn't do that, so the is probably something wrong with your regular expression. If I had to guess an unescaped dollar sign but without the exact it's hard to say what's wrong.
Okay that is fixed. Thanks anyway.

Can you tell me how to make setting with drop down to choose from 4 options?
What to type in optionscode
NVM. Please close this thread. Thanks!