Re: The difference between ereg and preg?

From: Date: Fri, 04 Aug 2006 17:21:24 +0000
Subject: Re: The difference between ereg and preg?
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-240132@lists.php.net to get a copy of this message
On Fri, 2006-08-04 at 13:03 -0400, John Nichel wrote: > > Perl compatible regexs are faster* and more powerful. Course, writing a > good Perl regex is an art form in itself (probably why O'Reilly released > a book just on regexs), and takes some time (and headaches) to master > (if one ever does master it). > > The difference in the people who use one or the other? Probably nothing > more than their background. Those of us who worked with Perl before php > are more than likely gravitate towards preg. Those who didn't, or had > little Perl regex experience more than likely went to the POSIX (ereg) > style as it's a bit easier to pick up. > > *I'm sure there are some out there who will dispute this. I use POSIX primarily because it was a standard and because PCRE was not originally enabled by default. Seems funny that the POSIX version is being deprecated *heh*. Cheers, Rob. -- .------------------------------------------------------------. | InterJinn Application Framework - http://www.interjinn.com | :------------------------------------------------------------: | An application and templating framework for PHP. Boasting | | a powerful, scalable system for accessing system services | | such as forms, properties, sessions, and caches. InterJinn | | also provides an extremely flexible architecture for | | creating re-usable components quickly and easily. | `------------------------------------------------------------'

« previous php.general (#240132) next »