
December 24th, 2004
02:52 AM
Neverside Newbie
Status: Offline!
regular expression syntax
those regular expressions seem to be quite perplexing for me to understand it. but it is so frequently used and is also very important when using replace functions. i had read through the php documents on regular expressions syntax but i still don't understand how to use them very well.
is there a website which, or anyone who, can elaborate it in a more clearer and easier way to understand?
thanks

December 24th, 2004
06:37 AM

December 24th, 2004
08:35 AM
Neversidian
Status: Offline!
i unno if you saw this, but here it is anyways. www.php.net/pcre
___________________
Neverside Development Director
PHP Snippets
BigToach.com - IT WORKS, TOACHY!

December 24th, 2004
03:47 PM
Neverside Newbie
Status: Offline!
thanks for the sites...
hmm...i read some and i am quite confused with the difference between a + and an *
both loops something but when i look into the php.net/pcre,
it says * is 0 or more quantifier and + is 1 or more quantifier
what does it mean?

December 24th, 2004
07:46 PM
Neversidian
Status: Offline!
something like this
you wanna find at least 1 instance of something then you use + but if you wanna see if it is there or it isnt. here is an example
1.) find a string that starts with the letter a
/^a+/i
2.) find a string that starts with big and can have anything else after it
/big*/i (so it could be 'big', 'bigtoach' etc)
___________________
Neverside Development Director
PHP Snippets
BigToach.com - IT WORKS, TOACHY!