http://www.perlmonks.org?node_id=177123


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.

¤