Omega -1911 am Freitag, 1. Dezember 2006 19:01: > Hi Rob & Dani, Hello Omega
> Thanks for your help!!! I will try the suggestion you made Rob and as soon > as I finish typing this, I'll try Dani's code. I had someone > contact me off-list and provided me with the following regex that > appeared to work. Please let me know what you think: > > my( $title, $event) = $data_string =~ > m|([^>]*)(?:</FONT></b>)([^\]]*)([^<]*)|; First I'd like to emphasize that Rob's suggestion (use a parser module, not a regex) is really the preferred way. Consequently, I should not have mentioned a regex... I see at least the following problems with the above regex (there are others, as well as in mine): - It captures three peaces of the input, while on the left side are only two variables to put the peaces in. - When I run it, it matches too much into $event (event up to the Ref # without the trailing ']' - the latter is put in $3). - ... In short: A parser module will avoid a lot of trickiness, pitfalls, error proneness, problems [pick the right english term(s) if present] :-) Just forget the regex path. Dani -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>