The contents of a simple form are sent to a Perl CGI in the server.
The Perl code is:
use CGI qw(:standard);
print "Content-type: text/html\n\n";
print "<html><hea d></head><body>Test ing Thruput<br>";
print "<script language="JavaS cript">";
print "</script>";
$value = param(myname);
print "$value<br> ";
$value = param(addr);
print "$value<br> ";
print "</body></html>";
If <script language="JavaS cript"> and the matching </script> tag are
output to the browser, it will not process -- the browser hangs. If
these two lines are commented out, the browser handles the page
without a problem.
Question: Cannot a CGI output an HTML page that includes JavaScript?
I'm either missing something basic, or making a dumb mistake.
Pat
The Perl code is:
use CGI qw(:standard);
print "Content-type: text/html\n\n";
print "<html><hea d></head><body>Test ing Thruput<br>";
print "<script language="JavaS cript">";
print "</script>";
$value = param(myname);
print "$value<br> ";
$value = param(addr);
print "$value<br> ";
print "</body></html>";
If <script language="JavaS cript"> and the matching </script> tag are
output to the browser, it will not process -- the browser hangs. If
these two lines are commented out, the browser handles the page
without a problem.
Question: Cannot a CGI output an HTML page that includes JavaScript?
I'm either missing something basic, or making a dumb mistake.
Pat
Comment