rlm@0: #!C:/strawberry/perl/bin/perl.exe
rlm@0:
rlm@0: # this is an example script of how you would use coderefs to define
rlm@0: # your CGI::Ajax functions.
rlm@0: #
rlm@0: # NB The CGI::Ajax object must come AFTER the coderefs are declared.
rlm@0:
rlm@0: use strict;
rlm@0: use CGI::Ajax;
rlm@0: use CGI;
rlm@0:
rlm@0: my $q = new CGI;
rlm@0:
rlm@0: my $exported_fx = sub {
rlm@0: my $value_a = shift;
rlm@0: my $iq = new CGI;
rlm@0: my $a = $q->param('a');
rlm@0: my $b = $q->param('b');
rlm@0: my $test = $q->param('test');
rlm@0: return(
rlm@0: 'entered value was: ' . $value_a .
rlm@0: '
a was: ' . $a . "..." .
rlm@0: '
b was: ' . $b . "..." .
rlm@0: '
test was: ' . $test . "..."
rlm@0: );
rlm@0: };
rlm@0:
rlm@0:
rlm@0: my $Show_Form = sub {
rlm@0: my $html = "";
rlm@0: $html .= <
rlm@0: CGI::Ajax Example
rlm@0:
rlm@0:
rlm@0:
rlm@0:
rlm@0: