$shell = "/bin/sh"; system $shell "-sh","-norc"
system { "/bin/sh" } "-sh","-norc"
Forces interactive shell In Perl5, a useful trick is to use the escape sequence \Q \E to quote metacharacters so that they won't be interpreted: print if m/\Q$user_pattern\E/o;

Oooh @ $|++ and its applications to cgi
#!/usr/bin/perl ### Strange MySQL Error ### use warnings; use CGI; use DBI; print "Content-type: text/html\r\n\r\n"; my $time = localtime; my $driver = "DBI:mysql:foo"; my $username = "bar"; my $password = "baz"; $dbh = DBI->connect($driver, $username, $password) or die $DBI::errst +r; open(F, "file.txt") or die; while(<F>){ $bat = somefunction($_); my $entry_added = $dbh->do("INSERT INTO `foo`.`table` (`boo`, `bat`) +VALUES ('$_', '$bat')", undef, 'DONE') or &dbdie; }
[download]

http://perlmonks.com/index.pl?node_id=105674