in reply to How can I unzip certain file in zip file?

How can it run without '@ARGV' or How can it run in CGI?

Well... if you set $zipName and $memberName[0] in the code, you could disble the parts that reads out @ARGV

If you want to run it inCGI, take a look at the CGI module.
  • Comment on Re: How can I unzip certain file in zip file?

Replies are listed 'Best First'.
Re: Re: How can I unzip certain file in zip file?
by integral (Hermit) on Jan 29, 2003 at 20:19 UTC
    Since under CGI you have named parameters instead positional parameters, you'll have to restruture your code to extract the parameters at the top of your script. Also in your for loop instead of looping on @ARGV, you would instead loop on the array in your querystring.
    # at the top to load your parameters # call the script as script.pl?zipName=blah&members=abc&members=xyz my $zipName = $cgi->param('zipName'); my @members = $cgi->param('members'); print 'usage message' unless $zipName and @members

    --
    integral, resident of freenode's #perl