Wednesday, February 17, 2010

Handling issues related to functions deprecated in PHP5.3

Recently one of our Customers has updated php and mysql version from 4.x to 5.x in the hosting server of their Joomla based website.

After doing this upgration/migration, many pages were not working. They started giving error messages such as, "Deprecated: Function eregi() is deprecated..."

We resolved these issues by replacing deprecated functions with equivalent functions.

For example, replaced split() with explode(). And, replaced eregi() with preg_match('/regexp/i',,).

Note that we should select appropriate modifier in regular expression in the preg_match argument. i-e The modifier should not be the part of the regular expression statement. We need to use rarely used character as modifier. For example we can use "~" as modifier.

This blog post was very helpful for resolving many issues.

I think Joomla is used by many people. But still I couldn't find any easy way to update the Joomla code automatically according to php/mysql upgration.

If you know any good article for doing php/mysql up-gradation you can mention it thro' comments. And, you can share your up-gradation experience.

More Articles...

No comments:

Search This Blog