
Danni
Novice
Nov 16, 2002, 2:20 PM
Post #1 of 5
(10915 views)
|
Catching optional newlines in .*?
|
Can't Post
|
|
Ive gotten a little stuck trying to figure this out. This is part of what will be a very large complex regex. I need the last (.*) to capture the whole description but it breaks on newlines. Any clues?
while ($catalog =~ / (.*?)\n # capture title (.*?)\sCatalog\s\#:\s(.*?)\sList:\s(.*?)\sSale:\s(.*?)\n # capture other stuff (.*)\n # Capture description /gxm) { #do stuff } This needs to match the following
Anime Keychain Assortment KEY Catalog #: PACK1202 List: $18.00 Sale: $12.99 Four of the coolest Keychains out there. One each from Tenchi, DBZ, Sailor Moon, and Cardcaptors. Start your collection today. Arc the Lad SeriesSet DVD Catalog #: PACK1209 List: $179.70 Sale: $99.99 Contains the entire series of Arc the Lad on DVD. Battle Athletes Pack DVD Catalog #: PACK1126 List: $164.78 Sale: $123.99 Contains all DVD volumes of the Battle Athletes Victory and Battle Athletes series.
|