gasmalaged
<html><head><title>Gas mileage</title></head>
<body><center>
<form method=”post” action=”gasmileage.cgi”><br><br>
<h1>gas mileage”</h1><br>
<label for=”distance”>distance(miles):</label><br>
<input type=”text” name=”distance”><br><br>
<label for=”gallons”>Gallons used:</label><br>
<input type=”text” name=”gallons”><br><br>
<input type=”submit” value=”送信する”><br>
<input type=”reset” value=”リセット”>
</form></center>
</body></html>
#!/usr/bin/perl
BEGIN{$|=1;print”Content-type:text/html\n\n”;open(STDERR,”>&STDOUT”);}
use CGI;
$query=new CGI;
$distance=$query->param(‘distance’);
$gallons=$query->param(‘gallons’);
#print”$distance\n”;
#print”$gallons\n”;
$answer = $distance / $gallons;
print”<p>answer is $answer</p>”;
today miss take is
$distance=$query->param(‘distance’); good
$gallons=$param->(‘gallons’); x