Linux Systems Administrator
Jupitermedia
US-AZ-Tucson

Justtechjobs.com Post A Job | Post A Resume

Learning to Use Regular Expressions by Example
This site I'm working on relies heavily on user input through forms, and all that data needs to be checked before being sent a database. I knew PHP3's regular expression functions should solve my problem, but I didn't know how to form the regular expressions in the first place. What I needed were some sample strings--obviously the first places I looked were the PHP3 manual and the POSIX 1002.3 specification, but they don't help much in the way of exemplifying. Adding to that, I had a really hard time finding good literature on the Web about the subject. I eventually got to know how to do it, mostly through experimenting, and seeing there wasn't much to it, I decided to write down this straight-out introduction to the syntax and a step-by-step on building regular expressions to validate money and e-mail address strings. I just hope it manages to clear the fog around the subject for all you fellow programmers.
Basic Syntax of Regular Expressions
First of all, let's take a look at two special symbols: '^' and '$'. What they do is indicate the start and the end of a string, respectively, like this:
  • "^The": matches any string that starts with "The";
  • "of despair$": matches a string that ends in the substring "of despair";
  • "^abc$": a string that starts and ends with "abc" -- that could only be "abc" itself!
  • "notice": a string that has the text "notice" in it.
You can see that if you don't use either of the two characters we mentioned, as in the last example, you're saying that the pattern may occur anywhere inside the string -- you're not "hooking" it to any of the edges.
There are also the symbols '*', '+', and '?', which denote the number of times a character or a sequence of characters may occur. What they mean is: "zero or more", "one or more", and "zero or one." Here are some examples:
  • "ab*": matches a string that has an a followed by zero or more b's ("a", "ab", "abbb", etc.);
  • "ab+": same, but there's at least one b ("ab", "abbb", etc.);
  • "ab?": there might be a b or not;
  • "a?b+$": a possible a followed by one or more b's ending a string.
You can also use bounds, which come inside braces and indicate ranges in the number of occurences:
  • "ab{2}": matches a string that has an a followed by exactly two b's ("abb");
  • "ab{2,}": there are at least two b's ("abb", "abbbb", etc.);
  • "ab{3,5}": from three to five b's ("abbb", "abbbb", or "abbbbb").
Note that you must always specify the first number of a range (i.e, "{0,2}", not "{,2}"). Also, as you might have noticed, the symbols '*', '+', and '?' have the same effect as using the bounds "{0,}", "{1,}", and "{0,1}", respectively.
Now, to quantify a sequence of characters, put them inside parentheses:
  • "a(bc)*": matches a string that has an a followed by zero or more copies of the sequence "bc";
  • "a(bc){1,5}": one through five copies of "bc."
There's also the '|' symbol, which works as an OR operator:
  • "hi|hello": matches a string that has either "hi" or "hello" in it;
  • "(b|cd)ef": a string that has either "bef" or "cdef";
  • "(a|b)*c": a string that has a sequence of alternating a's and b's ending in a c;
A period ('.') stands for any single character:
  • "a.[0-9]": matches a string that has an a followed by one character and a digit;
  • "^.{3}$": a string with exactly 3 characters.
Bracket expressions specify which characters are allowed in a single position of a string:
  • "[ab]": matches a string that has either an a or a b (that's the same as "a|b");
  • "[a-d]": a string that has lowercase letters 'a' through 'd' (that's equal to "a|b|c|d" and even "[abcd]");
  • "^[a-zA-Z]": a string that starts with a letter;
  • "[0-9]%": a string that has a single digit before a percent sign;
  • ",[a-zA-Z0-9]$": a string that ends in a comma followed by an alphanumeric character.
You can also list which characters you DON'T want -- just use a '^' as the first symbol in a bracket expression (i.e., "%[^a-zA-Z]%" matches a string with a character that is not a letter between two percent signs).
In order to be taken literally, you must escape the characters "^.[$()|*+?{\" with a backslash ('\'), as they have special meaning. On top of that, you must escape the backslash character itself in PHP3 strings, so, for instance, the regular expression "(\$|¥)[0-9]+" would have the function call: ereg("(\\$|¥)[0-9]+", $str) (what string does that validate?)
Just don't forget that bracket expressions are an exception to that rule--inside them, all special characters, including the backslash ('\'), lose their special powers (i.e., "[*\+?{}.]" matches exactly any of the characters inside the brackets). And, as the regex man pages tell us: "To include a literal ']' in the list, make it the first character (following a possible '^'). To include a literal '-', make it the first or last character, or the second endpoint of a range."
For completeness, I should mention that there are also collating sequences, character classes, and equivalence classes. I won't be getting into details on those, as they won't be necessary for what we'll need further down this article. You should refer to the regex man pages for more information.
[ Next Page ]


Comments:
RE: Delete word in a sentence which is in bramattbarrah09/25/07 16:14
Need helpIvan Panchev08/14/07 04:09
A note about "^abc$"Ivan Panchev08/13/07 03:00
Delete word in a sentence which is in bracketBetül07/27/07 02:44
RE: email validationRegExpress 2.006/16/07 05:09
on line registrationsata05/06/07 00:30
Help on reg exp in phpPraveen Mohite02/10/06 02:15
Need to extract multiple lines from log fileSumit Kumar11/24/05 06:27
holdem pokerholdem poker11/17/05 12:09
phentermine rxphentermine rx11/17/05 12:00
texas holdem pokertexas holdem poker11/17/05 11:02
free online pokerfree online poker11/17/05 07:41
cheap phenterminecheap phentermine11/17/05 05:08
texas holdem pokertexas holdem poker11/17/05 04:00
cheap phenterminecheap phentermine11/17/05 03:46
bootsboots11/17/05 03:11
meridiameridia11/17/05 03:03
phentermine codphentermine cod11/17/05 01:53
phentermine codphentermine cod11/16/05 23:46
diamondsdiamonds11/16/05 22:15
texas hold'emtexas hold'em11/16/05 22:06
viagra rxviagra rx11/16/05 21:37
order hoodiaorder hoodia11/16/05 21:09
meridia rxmeridia rx11/16/05 20:04
cingular ringtonescingular ringtones11/16/05 19:13
generic viagrageneric viagra11/16/05 17:32
cheap meridiacheap meridia11/16/05 17:23
phenterminephentermine11/16/05 17:18
buy shoesbuy shoes11/16/05 17:04
phentermine codphentermine cod11/16/05 15:32
holdem pokerholdem poker11/16/05 14:59
phentermine rxphentermine rx11/16/05 13:02
pokerpoker11/16/05 12:49
video pokervideo poker11/16/05 12:46
casino gamescasino games11/16/05 12:43
phentermine rxphentermine rx11/16/05 11:03
buy phenterminebuy phentermine11/16/05 10:27
buy phenterminebuy phentermine11/16/05 09:47
cheap adipexcheap adipex11/16/05 09:05
xenicalxenical11/16/05 08:57
forexforex11/16/05 08:25
texas hold emtexas hold em11/16/05 08:23
online pokeronline poker11/16/05 08:12
online pokeronline poker11/16/05 08:12
diamond ringsdiamond rings11/16/05 07:05
weight loss pillsweight loss pills11/16/05 06:13
casinocasino11/16/05 06:04
phenteminephentemine11/16/05 05:55
free online pokerfree online poker11/16/05 05:50
online casinoonline casino11/16/05 05:15
meridiameridia11/16/05 05:13
cheap phenterminecheap phentermine11/16/05 05:02
free pokerfree poker11/16/05 04:41
cialiscialis11/16/05 04:14
loansloans11/16/05 03:59
free texas holdemfree texas holdem11/16/05 03:50
buy phenterminebuy phentermine11/16/05 03:44
online pokeronline poker11/16/05 03:42
online casinoonline casino11/16/05 01:31
phenteminephentemine11/16/05 01:29
phentermine rxphentermine rx11/16/05 01:09
buy meridiabuy meridia11/16/05 01:07
cheap phenterminecheap phentermine11/15/05 23:12
texas pokertexas poker11/15/05 22:06
diamondsdiamonds11/15/05 22:00
Forex trading softwareForex trading software11/15/05 21:25
buy phenterminebuy phentermine11/15/05 21:03
buy phenterminebuy phentermine11/15/05 21:02
phenterminephentermine11/15/05 19:07
forexforex11/15/05 18:54
phenterminephentermine11/15/05 18:40
poker roompoker room11/15/05 18:35
free ringtonesfree ringtones11/15/05 18:18
cheap phenterminecheap phentermine11/15/05 17:46
RE: Re Validation expression in regular expresionJeXuS11/13/05 03:27
Re Validation expression in regular expresionsiva11/11/05 03:50
RE: Strip ALL that is between < and >alvense11/10/05 21:52
Match a wordrobinson10/28/05 00:34
Regular expression mahipal saran10/15/05 11:05
Rajesh Kumar for Programming helprajesh10/15/05 06:17
RE: Validating money string exampleJeff10/04/05 12:58
pokerpoker09/16/05 07:10
Regular ExpressionNakeshia Lewis09/05/05 16:21
Validating money string examplejamie08/26/05 19:17
RE: Regular expressions..Vaskar Basak08/18/05 14:28
RE: date validationneedhelp08/03/05 00:10
RE: Regular expressions..Nick sherman07/26/05 13:27
implement a variable in a regular expression selva06/28/05 02:35
Regular Expression string format check.Girish Sharma06/24/05 08:49
Reading, writing, updating filesBen_1205/24/05 04:36
RE: Mailing Addresscutiepie04/24/05 01:27
regular expression to match valid Windows XP Fernando04/19/05 12:26
RE: Infromation between div tag printedMukesh Variya04/04/05 06:41
PHP 5 regexMark Furtney04/03/05 18:21
+ is legitimate for an email usernameDavid03/28/05 08:38
ereg_replace() trim() emulationFuRiOuS103/23/05 02:28
Great article..Scott - phphq.net02/26/05 00:14
php learningKhawar01/23/05 23:46
Great. Tnx !Naser Ezzati01/09/05 15:29
Great ArticleMichael Lombard12/28/04 05:34
Simply SuperbMathar12/23/04 20:41
RE: password validationNima12/16/04 22:03
Its really helpfulMainak Bagchi11/21/04 03:36
Good to LearnA.V.Madhav09/15/04 04:21
Thank YouRob Warwick09/05/04 22:52
excellent article !!, thanxManish Mohania08/09/04 04:45
RE: numbersThomas Chua05/21/04 02:04
cheerschuck05/07/04 06:48
Great TutAdrian03/01/04 14:13
THANKS ALOT!Parazuce02/20/04 22:31
Regular expressions..Reddy02/05/04 14:18
Allowing <? ?> tags in Regular ExpressionAndy Lancaster01/13/04 05:03
password validationCarmel01/09/04 16:05
Help meTarzan01/07/04 23:52
help mevibra12/25/03 17:25
RE: Validating username? an easier way?Nesher11/03/03 13:41
Thanks! Darioshekar10/02/03 02:40
thankful kiwimikecandle09/07/03 05:25
Brilliant Article, thanks DarioTom Bamford08/18/03 13:18
RE: This is a Comments page, not a support forumcieplyromek07/31/03 08:08
Best RegExp Article I've Read!Scott07/07/03 21:22
Thanks Dario !Benjamin Lacaze06/14/03 06:08
This is a Comments page, not a support forumMaggie04/29/03 01:59
RE: date validationChris04/08/03 01:27
date validationGothami02/20/03 05:07
RE: Validating username? an easier way?Patrick Reilly02/13/03 10:34
RE: Obtaining a whole HTML section from a pagFrugle01/14/03 06:09
RE: email validationTHM12/11/02 09:31
a valid person name formatLuis Costa12/09/02 19:18
RE: Removing Whitespacesjavier12/06/02 18:41
RE: Removal of white spacesjavier12/06/02 18:31
RE: Implement a variable in a regexpRegexp12/04/02 17:29
RE: regular expressionnigel11/27/02 02:15
Escpaing double quote in a rangeJason11/05/02 19:46
preg_replace on that regular expressionmelbiz11/01/02 11:14
Thank you, well done!beaty10/31/02 10:06
warning message ? Selim MERİÇ10/30/02 10:07
RE: Problem with alt-attributs in image-tagsKyle10/26/02 01:36
RE: detecting repetitive characters (e.g. ffffff)Dirk te Winkel10/18/02 20:23
Problem with alt-attributs in image-tagsDevel10/15/02 04:40
Some ereg I need to do in PHP...Philippe Veronneau10/03/02 11:39
RE: NOT notationTom Myer10/02/02 09:02
RE: checking a file extension ?? help pleaseJean-Marc Molina [goa103]09/29/02 15:40
Identify HTML tags with regular expressionMarty Slade09/24/02 13:52
RE: How to allow spaces in RegExp?? Help!!iodine09/24/02 10:55
Replace within HTMLGreg DiFalco09/24/02 09:56
Apostrophe in email usernameMark Edwards09/23/02 21:13
RE: How to Determine a String is Only Alphabet?Richard France09/23/02 20:31
numbersSean John09/12/02 13:10
Upload querysharad mittal09/12/02 11:56
RE: How to limit the # of characters in a stringhammer09/12/02 11:54
Help me with replace tag [ ], good exampleAngelRoyo09/08/02 20:20
How to allow spaces in RegExp?? Help!!Florian Bruch08/30/02 19:38
NOT an email domainRon Shannon08/29/02 02:53
Regular Expression LibraryJean-Marc Molina08/22/02 07:13
RE: How to Determine a String is Only Alphabet?Jean-Marc Molina08/22/02 06:05
RE: Replace string OUTSIDE of HTML tagsJens08/21/02 19:07
Validating username? an easier way?James08/21/02 14:41
RE: Capitalizationmatthew08/19/02 15:22
checking a file extension ?? help pleasemike08/15/02 12:19
New User! Reg EXPRnik_crash08/09/02 05:04
Implement a variable in a regexpDavide08/09/02 03:59
Replace string OUTSIDE of HTML tagsWalter08/08/02 00:21
Number to Figure Conversion FunctionSKM08/07/02 04:53
RE: NOT notationSteve08/06/02 06:09
RE: New User! Reg EXPRSteve08/05/02 07:47
NOT notationPaul Gibbs07/31/02 06:36
RE: Error in e-mail exampleJuan Londono07/30/02 20:56
Error in e-mail examplePeter Simard07/27/02 12:42
How to limit the # of characters in a stringCory Gagliardi07/23/02 19:12
New User! Reg EXPRGaurav_k07/22/02 06:29
eregreplace with mirc colorcodeMatt Lush07/18/02 21:58
How to Determine a String is Only Alphabet?Kwangho Seo07/18/02 08:23
another question about reg exprbadsocietyguy07/15/02 16:57
RE: Capitalizationmstenz-design07/14/02 17:42
CapitalizationDzigner07/10/02 20:13
RE: One more question on regexpVictor07/08/02 13:34
RE: ereg_replace img tags -- PLEASE HELP!!!Victor07/03/02 13:28
Expresiones regulares Urgente!!!Victor Palmar07/02/02 21:34
ereg_replace img tags -- PLEASE HELP!!!vic06/28/02 09:34
RE: Stripping spaces, dashes etc.Elwaleed Elbashier06/27/02 08:55
RE: Removal of white spacesElwaleed Elbashier06/27/02 08:39
RE: regex tld validationElwaleed Elbashier06/27/02 08:10
To validate websites namesElwaleed Elbashier06/27/02 07:29
One more question on regexpSteve06/25/02 17:17
regexp questions (3)Steve06/25/02 16:26
Strip commentsAlex06/24/02 03:59
Mutil eregi_replace() from 1 stringRob06/23/02 03:04
Another Hard one. Pls.... helpGigi06/22/02 19:27
RE: how can i do to remove every html code Emre Sokullu06/22/02 18:58
txt2regexHugo Cisneiros06/20/02 15:58
how can i do to remove every html code alex06/19/02 12:12
delete extract of patternsteve06/16/02 15:41
RE: getting rid of imagesHenry06/13/02 07:56
RE: Removal of white spacesBruno06/13/02 05:08
Find lines that contains a string but not anoMaxime Ducharme06/11/02 12:23
RE: Everything between <a an /a>Lizard06/11/02 08:57
Replacing HTML Attributes ?Karthik06/10/02 05:51
Everything between <a an /a>Clay Tutaj06/09/02 22:02
getting between something and something elsetuor06/09/02 15:30
RE: How to parse a string.Digital Cowboy06/07/02 13:03
How to parse a string.mfc506/06/02 11:13
checking the length of a text areagriffspot06/03/02 16:18
'AND' equiv?kimm05/31/02 07:40
Replacing characters with tildeRafa05/31/02 07:08
RE: regular expressiondaniel05/29/02 05:59
RE: how do i read href="blah"dave05/28/02 16:31
RE: Why do 80% of these questions go unanswered?Paulo05/20/02 16:59
How to use RegExp to parse data betn. Html tavikramvj05/20/02 06:53
Get the html tags template without content ??Deepak Jain05/20/02 02:37
regular expressionTapas K Mandal05/17/02 16:01
expressionsNiloy05/11/02 15:11
RegExp for date to validate month/leap yearVentura Sampra05/07/02 09:33
help me quick, pleaseCash05/03/02 09:20
Using RegExp to replace img-Tags?Tom05/02/02 05:19
regular expressionsA. GANESH05/01/02 11:39
RE: how to parse XML, looking for fields of dataChris04/30/02 12:29
RE: how to parse XML, looking for fields of dataGrumbler04/29/02 12:15
if and until problems with expr and OPTINDKristin04/28/02 21:01
how do i read href="blah"Max04/27/02 00:48
RE: Match Alpha or NumericAllard04/24/02 14:13
RE: eregi's pattern problemossi04/23/02 07:20
Match Alpha or NumericRicta04/16/02 20:30
how to parse XML, looking for fields of dataDan04/16/02 18:06
eregi's pattern problemMagnus Nirgi04/14/02 16:38
quoting, sed, and newline charKristin04/14/02 11:16
RE: print html tags to be displayedBrian Douros04/11/02 22:14
print html tags to be displayedharneu04/10/02 05:23
RE: help with regular expressionsKristin04/06/02 23:39
RE: Help on reg expression.deepak04/06/02 04:39
Why do 80% of these questions go unanswered?A student04/05/02 16:55
RE: Showing sourcecode in my guestbookThomas04/05/02 11:16
help mebabak04/04/02 03:31
Help on reg expression.Phani04/03/02 20:34
form validationCraig Blackman04/02/02 15:28
help with regular expressionsKristin03/30/02 18:49
Ending dot for FQDN is validHugo van der Kooij03/30/02 17:19
Matching img tags (advanced)inki03/28/02 06:02
Replacing URL with link - Problemciuc03/27/02 12:14
problems replacing image path !aanzi03/26/02 12:32
More accurate email validationsaanti03/25/02 10:35
Exclusion ... ?Jules03/22/02 09:29
regex tld validationmitch03/20/02 04:53
RE: REMOVING LANGUAGEKurt Willey03/19/02 14:12
Stripping spaces, dashes etc.Paul Stewart03/14/02 09:17
regex help!Ben Summers03/11/02 20:07
REMOVING LANGUAGEFraser03/08/02 14:48
How to strip all HTML and make links of urls?Laban03/03/02 08:41
RE: Error with email validation expressionMarshall03/02/02 14:21
Using ereg to find char's for *nix usernamesJohn Seth02/28/02 16:56
Final piece of URL Matching RE neededJAM02/26/02 07:50
RE: Removal of white spacesRobin Collins02/24/02 23:42
Finding images in a mysql table...Erling02/22/02 11:46
RE: how to detect if a string to have spaces?Erik Neves02/20/02 10:06
RE: Replace space for _ between < and >Erik Neves02/20/02 10:02
How to list files, without a particular type?Milind02/19/02 14:11
Error with email validation expressionPras02/18/02 18:59
how to detect if a string to have spaces?christian02/17/02 09:27
RE: IP ADDRESSChris02/13/02 03:27
Spam FilterJohn Genovese02/12/02 21:59
Need Help!Dustin Kaufmann02/10/02 23:14
Java regular ExpressionPhani02/07/02 14:54
how to...?steve02/06/02 23:59
RE: How to strip all script tags and contents?Barnie02/05/02 05:35
finding 3 words in a stringMatt01/31/02 10:40
Not able to print session variableNikhil01/25/02 03:28
RE: negating phrasesChen 'FireFly' Avinadav01/22/02 14:01
RE: help with multiple occurrence replacementChen 'FireFly' Avinadav01/22/02 13:56
RE: getting rid of imagesChen 'FireFly' Avinadav01/22/02 13:49
getting rid of imagesBenjamin01/21/02 07:06
help with multiple occurrence replacementFrederick Kuhne01/20/02 00:15
negating phrasesbilly01/19/02 14:44
ALL between " AND "Torsten01/19/02 08:08
RE: Text Inside HTML TagsSean S01/14/02 23:43
Replace space for _ between < and >Erik Neves01/13/02 13:18
Matching phrasesJosi01/11/02 18:45
Case-insensitive replacementsIlych01/10/02 05:27
hyphen troubleThanatos01/09/02 15:12
NOT finding a whole wordMartin Sudmann01/09/02 06:36
RE: Remove Tag ImgLuke Hartman01/07/02 16:59
Remove Tag ImgSuwandi01/04/02 10:28
RE: Help with match please...Mamil01/04/02 06:25
RE: What's wrong?Mamil01/04/02 06:14
RE: Matching quotesMichael Harney01/03/02 14:32
RE: parse error and moreMamil01/03/02 07:30
RE: Text Inside HTML Tagssteve tattersall01/01/02 06:55
parse error and moreGeorge Van Tuyl12/28/01 12:12
string1PARSEMEstring2?freezy12/22/01 21:03
RE: Even more difficultWouter Alink12/20/01 07:55
RE: HELP in getting strings within html tagsAaron M. Reiff12/19/01 11:34
RE: Stop this comments!Soapy12/19/01 05:42
RE: Text Inside HTML TagsTrAsH12/17/01 13:17
RE: Strip ALL that is between < and >TrAsH12/17/01 13:12
Help with regular expressionJon12/17/01 06:18
RE: RegExp for dateNayt Grochowski12/10/01 17:07
RegExp for dateMike12/07/01 13:48
RE: detecting repetitive characters (e.g. ffffff)Dwivedi, Ajay kumar12/06/01 04:17
RE: web site addressandrew12/04/01 17:16
remove last numberrev aaron12/03/01 23:47
How to strip all script tags and contents?Rigel12/02/01 04:20
Need help srelysian11/30/01 10:29
RE: Regex for image file nameBruno11/28/01 10:12
What's wrong?Marc11/27/01 04:55
RE: Strip ALL that is between < and >Bruno11/26/01 03:33
RE: Strip ALL that is between < and >Bruno11/26/01 03:19
RE: Strip ALL that is between < and >LeChuck11/25/01 23:24
web site addressIan Torrilla11/25/01 13:53
Gather all date in between colonsDave Wilcock11/23/01 22:50
How to remove all the '\' characterspaul11/23/01 17:10
RE: strip everyting after last / Devil11/15/01 21:25
Strip ALL that is between < and >Jaska11/15/01 17:44
RE: Matching quotesMike de Clerck11/12/01 05:08
RE: Remove return?Toby11/11/01 08:44
Help with match please...Jon N.11/10/01 15:55
Regex for image file nameBilly11/04/01 17:21
regexp : need to match &lta&gt tagJan Odvarka11/04/01 14:42
help thisgopal10/30/01 02:07
Problems with question markShawna Gibbs10/26/01 16:03
RE: help preg_place()Ulrich Balling10/24/01 08:52
RE: help preg_place()Ulrich Balling10/24/01 08:37
RE: Matching quotesUlrich Balling10/24/01 08:21
Cool!Tobias Beuving10/24/01 07:32
RE: Remove return?jason10/21/01 22:47
Removing SELECTED Font TagsSteve Cobb10/21/01 16:02
Thank you: very clearPatrick Lee10/16/01 02:46
help preg_place()tho10/15/01 21:00
RegExp and Other languagesDaniel10/08/01 02:33
RE: Obtaining a whole HTML section from a page?!charley09/28/01 15:47
Change GenderDamon09/16/01 00:54
RE: strip off alpha and leading 0'sDoug09/07/01 07:50
strip off alpha and leading 0'sDoug09/06/01 09:28
how2 extract this string?polerio 09/04/01 06:13
RE: how 2 ereg_replace all matches?binaural09/03/01 23:49
Stop this comments!Mike08/30/01 13:14
Replace Characters!May08/29/01 18:25
keywords - syntax diagramAaron08/24/01 23:13
query stringPaul08/23/01 12:36
RE: IP ADDRESSDario Gomes08/23/01 07:31
strip everyting after last / Neil Kessler08/21/01 09:25
RE: IP ADDRESSyoPCix08/21/01 04:04
RE: Obtaining a whole HTML section from a page?!Alex08/16/01 04:16
Double & Single Quotation Marks.Jim Dam08/15/01 16:17
Remove return?Mikael Johansson08/15/01 09:43
Validating IRC nicknamesBoris08/15/01 08:07
Replacing a custom include tag with a fileObi Nwosu08/14/01 22:40
Returning everything between { and }?Static08/10/01 17:49
Highlighting Code Within TagsEric08/09/01 09:42
RE: String between HTML tagsBretticus08/08/01 01:51
RE: Obtaining a whole HTML section from a page?!Bretticus08/08/01 01:30
RE: Obtaining a whole HTML section from a page?!Goober Wilson07/31/01 18:05
COLLATING .. problems PHPJim Levett07/27/01 02:34
Text Inside HTML TagsBen Davis07/24/01 12:44
National charactersW.Piskorz07/24/01 05:04
how to use regex to insertlog apache to mysqlArlyn07/21/01 02:52
RE: hard one, please helpaugustine07/12/01 03:21
RE: ereg and special charactersclk5507/12/01 02:32
detecting repetitive characters (e.g. ffffff)Jason07/08/01 09:45
eregi_replace w/more then 1 string occuranceJay07/07/01 14:16
Truncate stringMartin Kramer07/06/01 03:54
HELP in getting strings within html tagsjaney07/02/01 19:56
RE: hard one, please helpMichael Harney06/26/01 11:42
RE: ereg and special charactersChad Siefert06/20/01 09:53
RE: IP ADDRESSThomas Kristensen06/20/01 05:02
RE: hard one, please helppriti06/18/01 21:57
pattern matching in a loopMichael Richardson06/08/01 18:00
Replace a html tag with variableScott06/08/01 03:25
Obtaining a whole HTML section from a page?!Kyle Anderson06/07/01 17:06
RE: hard one, please helpDravine06/07/01 10:55
RE: hard one, please helpJelle06/05/01 02:14
RE: hard one, please helpPeter McNulty06/04/01 14:37
RE: String between HTML tagsgon05/31/01 13:24
RE: hard one, please helpgon05/31/01 13:17
regular expressions anyonegon05/31/01 12:59
counting wourds in a textDentor Alex05/31/01 08:17
RE: ereg_replace of @@@something@@@Kay05/28/01 14:06
Replace on relative pathUwe Thaden05/25/01 02:23
RE: hard one, please helpOnno Schmidt05/23/01 14:32
RE: hard one, please helpOnno Schmidt05/23/01 14:26
IP ADDRESSmauro05/22/01 02:53
RE: hard one, please helpMichael Mann05/21/01 15:22
RE: striping multiple occurences of any characterLord Odin05/19/01 15:12
RE: hard one, please helpLord Odin05/19/01 14:55
hard one, please helpAnderson05/18/01 06:44
Showing sourcecode in my guestbookAte Bontjer05/16/01 21:30
&#92;] won't work use &#92;x5dcabo05/11/01 01:48
RE: How to trim trailing charactersMichael Svazas05/03/01 21:06
continuing the hearty moron traditionTao Chones04/26/01 02:58
I'm a maroonTao Chones04/26/01 01:32
Split CSV-File with INSIDE Delimiters ??? frusti04/24/01 16:12
RE: Removing Font Tagsthe.strawman04/19/01 03:18
How to trim trailing charactersNozer Damania04/18/01 13:57
changing ip address to subnetshs04/18/01 09:33
RE: Removing Font Tagsleith parkin04/17/01 22:43
RE: String between HTML tagsAndy04/16/01 07:34
ereg and special characters??yosimo04/13/01 12:42
striping multiple occurences of any characterDamjan Cilensek04/13/01 11:06
String between HTML tagsChris Empson04/13/01 08:42
ereg_replace of @@@something@@@chk04/11/01 09:05
to strip head and foot from html filelion03/27/01 12:17
How remove everything between / Part of URLJoao Correia03/22/01 16:38
Matching IP Conection's not from loopback.Pieter03/21/01 09:38
a word between bracketssebastien bernard03/21/01 06:55
Large matchingnoMaD03/20/01 18:10
How to exclude the () from URLOlga03/15/01 10:46
Bracket expressions x losing power ?Leander Berwers03/13/01 05:10
RE: Removing Font TagsAndrew03/12/01 18:01
Removing Font Tagsmike03/09/01 16:18
Mini ProgramC.R. Opela03/06/01 00:47
Taking a line after matching startDavid03/03/01 23:37
RE: how 2 ereg_replace all matches?Dario F. Gomes02/25/01 11:26
RE: Thank you!!!Dario F. Gomes02/25/01 11:18
Finding and replacing regular expressionsSchonarth02/25/01 11:16
RE: Time Dario F. Gomes02/25/01 11:11
Highlighting stringTarwin Stroh-Spijer02/25/01 01:21
RE: how 2 ereg_replace all matches?Jim Luttgens02/10/01 09:48
RE: how 2 ereg_replace all matches?clark02/05/01 15:17
regular expressionRafeeq C E02/02/01 07:46
replacing urls - please help!angel01/31/01 12:37
Thank you!!!Fotis01/30/01 09:38
RE: The meaning of ?(?!http)Carmen Vodislav01/17/01 11:29
RE: The meaning of ?(?!http)Rich Wall12/30/00 12:13
The meaning of ?(?!http)Phil Powell12/29/00 16:32
Time Tom Burriss12/28/00 17:22
Removing WhitespacesBrad B12/20/00 17:35
how 2 ereg_replace all matches?Lenny12/13/00 05:43
RE: "^abc$" ?Mark12/01/00 14:18
RE: "^abc$" ?Alex11/29/00 15:12
RE: "^abc$" ?Gildas Quiniou11/29/00 14:08
"^abc$" ?Mark11/28/00 16:42
email validationstephen11/22/00 08:14
RE: ereg and special charactersRafael Arancibia11/17/00 13:31
eregi_replaceRafael Arancibia11/17/00 13:17
RE: Regular Expressions in JavaHeiko Schlichting10/29/00 07:55
RE: Replace point "." --> wildcard (comma) ","Dario F. Gomes10/28/00 16:34
Regular Expressions in JavaBrian10/26/00 16:51
Replace point "." --> wildcard (comma) ","Marcello Junior10/23/00 13:48
RE: Matching quotesAdam Traver10/10/00 15:10
RE: Matching quotesDario F. Gomes10/06/00 17:01
RE: Removal of white spacesDario F. Gomes10/06/00 16:58
RE: theoreticalDario F. Gomes10/06/00 16:49
Removal of white spacesMichael Suess09/01/00 14:16
Matching quotesAdam Traver08/22/00 13:45
theoreticalNihhal Singh08/21/00 06:53
RE: ereg and special charactersDario F. Gomes08/14/00 11:48
RE: ereg from file to functionDario F. Gomes08/14/00 11:40
ereg and special charactersEric Jensen08/02/00 19:40
ereg from file to functionNor Aishah Hamid07/05/00 04:12
 

If you are looking for help, please post on the appropriate forum here. Your questions will be answered much more quickly.

Add A Comment:

Name:

Email:

Subject:

Message:

To reduce spam posts, messages are now manually approved

You are not [logged in]. That means your account will not get credit for this post.