[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: passing CGI paramters


[Please keep it on the list]

On 7/3/07, Craig Tussey <suppressed> wrote:
Thanks again for responding.  Here is the link to my
scratchpad.   Keep in mind that I was making entries
to the scratchpad in response to Clintons questions.

http://www.perlmonks.org/?viewmode=public;node_id=624649

Okay, you really aren't showing much code here.  From what you did
show, I'm guessing you're doing this:

my $govlevel = $page->param("str");
print_html();

sub print_html {
   print "blah blah $govlevel blah blah";
}

That doesn't work because the sub becomes a closure and never notices
when you create new versions of $govlevel.  The fix is to pass
$govlevel to the sub as a parameter.

- Perrin


Mail converted by mhonarc 2.6.15
This archive provided courtesy of JSW4.NET, Internet Hosting Services for Small Business.