Page 1 of 1

Preg Match Woes

Posted: Tue Jul 04, 2006 8:21 am
by Bigun
I've been Googling for decent tutorials and I've also searched here. I can't find anything that my brain can comprehend.

The best I could find was this: http://phptutorial.info/?preg-match

Which is an exact copy of this: http://us2.php.net/preg-match

:?

Anyway, I'm not asking for a private tutor, but I am asking for someone to explain this function in plain Engrish for me.

Posted: Tue Jul 04, 2006 8:26 am
by JayBird
Try reading the stickies in the Regex forum - viewforum.php?f=38

Posted: Tue Jul 04, 2006 8:27 am
by Jenk
preg* functions allow the use of Perl Compatible Regular Expressions

It's realy just soemthing you have to dive into.. at least for me it's really difficult to describe how to use it.

Download Regex Coach for practicing and have a read through the crash course stickies/threads in the Regex forum on this site.

Posted: Tue Jul 04, 2006 8:38 am
by Bigun
Is there a big difference between preg match and regex?

Posted: Tue Jul 04, 2006 8:42 am
by s.dot
preg_match() uses regex to find a match in a text string

Code: Select all

preg_match("/regex here/", $textstring);

Posted: Wed Jul 05, 2006 6:39 am
by Bigun
I found this, also quite useful for building regex expressions.

http://txt2regex.sourceforge.net/screenshots.html