Example 11-16. examples/regex/split_cgi.pl #!/usr/bin/perl
use strict;
use warnings;
my $str = 'fname=Foo&lname=Bar&email=foo@bar.com';
my %data = split /[=&]/, $str;
use Data::Dumper;
print Dumper \%data;
If you are interested in on-site trainings by the author, please
contact me directly.
|