The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
preg_replace Code Needs Repair (PHP DEPRECATED ERROR)
I'm in the process of updating to vB 3.8.9 & PHP 5.6 and I'm going thru fixing everything that needs to be fixed.
I've got a small piece of code from a plugin that I use on my forum that needs to be updated to comply with new PHP standards. Right now I'm getting PHP DEPRECATED errors in my PHP error log from this plugin. Here is the error I'm getting... Code:
PHP Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead I've narrowed the issue down to this piece of code... PHP Code:
I realize I could just ignore the error and continue on, but I would like to just update the code to comply with the new PHP standards since I'll have to deal with this issue eventually anyways. I know that preg_replace needs to be replaced with preg_replace_callback and that the "e" from "siUe" needs to be removed, but I don't know what other code changes needs to be made in order to get this working properly. I'm hoping someone can work their magic and help me out. Thanks in advance! |
#2
|
|||
|
|||
I guess something like this should work:
PHP Code:
|
2 благодарности(ей) от: | ||
Lynne, XenonKilla |
#3
|
|||
|
|||
You're the man Dave, the code worked perfect! Thanks a ton I really appreciate it!
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|