Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: Not equal, regular expressions

by frankus (Priest)
on Jun 25, 2002 at 16:06 UTC ( #177123=note: print w/ replies, xml ) Need Help??


in reply to Not equal, regular expressions

@edittypes = qw( htm html txt);
$regex = join('|', map{"\\.$_" }@edittypes);

$_ = $q->param('select');
inerror("You can only edit @edittypes") unless /$regex/i;
Using & will disable any proto you've got on a function.

--

Brother Frankus.

¤


Comment on Re: Not equal, regular expressions

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://177123]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (8)
As of 2014-12-25 14:30 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (160 votes), past polls