homepage Welcome to WebmasterWorld Guest from
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Home / Forums Index / Code, Content, and Presentation / PHP Server Side Scripting
Forum Library, Charter, Moderators: coopster & jatar k

PHP Server Side Scripting Forum

Migrating to PHP6
eregi, ereg, ereg_replace, eregi_replace functions

 7:30 pm on Nov 2, 2009 (gmt 0)

Going from 5 to 6 might call for a few more in depth script twists than 4 to 5!

As per the manual those functions
eregi, ereg, ereg_replace, eregi_replace
are deprecated since 5.0.3 and will be removed from PHP6

So in most cases if you use any of them you will need changing it by a preg_match() or a preg_replace()

Make a full scope search for the ereg family
and you could be in for a surprise

If you use PMA then hope for an updated PMA without eregi

If you use class.phpmailer.php
use the newer one (most recent is 5.1)

If you Flash library uses write.id3v2.php
then we must hope for a new release, so far it still uses eregi

Do you have more on the topic?



 7:30 pm on Nov 3, 2009 (gmt 0)

Not really. I'm just thankful I never did use the ereg* functions. I started off using the perl-compatible regular expression engine as soon as I realized it was bundled with PHP.


 7:37 pm on Nov 3, 2009 (gmt 0)

Other in list are removal of register_globals

Any idea of php6 release timeline?


 10:40 am on Nov 5, 2009 (gmt 0)

There is one post on php website for depreciated functions in 5.3

php 5.3 Migration [php.net]

Also there was one interesting article on Linux Magazine on getting ready for php6 here is Link [linux-mag.com]


 10:55 am on Nov 5, 2009 (gmt 0)

A keeper, thanks!


 12:29 pm on Nov 5, 2009 (gmt 0)

I have run into some show-stoppers in PHP 5.3 stable, including PRE-INIT queries with mysqli for which a bug was reported and patched in 5.3.2 DEV, which I had to pull from the snaps to get a domain running properly on a development site. IMHO, I would let 5.3 mature a bit more before using it for a live implementation. Use that migration guide for sure. There are other areas that may impact you.

I have a PHP 6 install too but haven't had as much time to dedicate to testing on it. I was actually a little surprised when they first announced the 5.3 branch but there must have been something in developer discussion that prompted the interim release.

Global Options:
 top home search open messages active posts  

Home / Forums Index / Code, Content, and Presentation / PHP Server Side Scripting
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved