For Programmers: Free Programming Magazines  


Home > Archive > PERL Beginners > August 2007 > More Perl and AJAX









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author More Perl and AJAX
Mathew Snyder

2007-08-29, 7:59 am

When passing a value from JavaScript to a Perl script, am I right in thinking
that the value received by the Perl script would be captured like my $value = @_;?

I'm trying to pass a value to Perl and by calling it directly in the browser and
passing a value to it like so
http://ajax.application.com/cgi-bin...ect=environment it
simply prints a zero to the browser.

Is that how it should be called when doing so directly?

--
Keep up with me and what I'm up to: http://theillien.blogspot.com
Andrew Curry

2007-08-29, 7:59 am

Yeah that's fine to use.

If you use CGI.pm

You can use

param('<NAME>')

i.e.

if (! param)
{
#
# do something
#
}
elsif (param('today'))
{
#
# do something
#
}

-----Original Message-----
From: Mathew Snyder [mailto:theillien@yahoo.com]
Sent: 29 August 2007 12:32
To: Perl Beginners
Subject: More Perl and AJAX

When passing a value from JavaScript to a Perl script, am I right in
thinking that the value received by the Perl script would be captured like
my $value = @_;?

I'm trying to pass a value to Perl and by calling it directly in the browser
and passing a value to it like so
http://ajax.application.com/cgi-bin...ect=environment it
simply prints a zero to the browser.

Is that how it should be called when doing so directly?

--
Keep up with me and what I'm up to: http://theillien.blogspot.com

--
To unsubscribe, e-mail: beginners-unsubscribe@perl.org For additional
commands, e-mail: beginners-help@perl.org http://learn.perl.org/



This e-mail is from the PA Group. For more information, see
www.thepagroup.com.

This e-mail may contain confidential information. Only the addressee is
permitted to read, copy, distribute or otherwise use this email or any
attachments. If you have received it in error, please contact the sender
immediately. Any opinion expressed in this e-mail is personal to the sender
and may not reflect the opinion of the PA Group.

Any e-mail reply to this address may be subject to interception or
monitoring for operational reasons or for lawful business practices.




Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com