Re: parsing special characters in perl
- From: "Thomas J." <jue@xxxxxxxxxxxxxxxxx>
- Date: 29 Aug 2006 14:58:39 -0700
soyebb@xxxxxxxxx schrieb:
if($subject =~
m/Read\s*product\s*information\s*for\s*the\s*([\s\w\&\:\;\"\'\-\_\>\<\\\/\)\(,\.\?\!\~\%\*\+\=\@\$]+)/gi)
the line parses everything after 'the' like it parseses "AMD Athlon"
but when it encounters the TM (symbol) it drops everything after that.
When I need everything till the end of line.
.... end of your variable, i think?
Is there a special symbol / wild card character that i can include in
this regular expression so as to keep parsing the text till the end of
line.
the answer depends on the charset of your input.
The "TM"-glyphe is not in your Character-Class.
If you want all to "end-of-line", why not using
(.+) instead of
([\s\w\&\:\;\"\'\-\_\>\<\\\/\)\(,\.\?\!\~\%\*\+\=\@\$]+) ?
Thomas
.
- Follow-Ups:
- Re: parsing special characters in perl
- From: soyebb
- Re: parsing special characters in perl
- References:
- parsing special characters in perl
- From: soyebb
- parsing special characters in perl
- Prev by Date: RE: Reading Excel spread*** into variables
- Next by Date: Re: splitting strings
- Previous by thread: parsing special characters in perl
- Next by thread: Re: parsing special characters in perl
- Index(es):