in reply to Getting a Regex Not to Match Again
will match "I want this", "that", or "those". It looks like you want it to match "I want this", "I want that", or "I want those". You'll need parens.$rx = "this|that|those"; /I want $rx/
or qr//:$rx = "this|that|those"; /I want (?:$rx)/;
$rx = qr/this|that|those/; /I want $rx/;
_____________________________________________________
Jeff[japhy]Pinyan:
Perl,
regex,
and perl
hacker, who'd like a job (NYC-area)
s++=END;++y(;-P)}y js++=;shajsj<++y(p-q)}?print:??;
|
|---|