August 1999
Intermediate to advanced
1488 pages
72h 53m
English
form.method
The method property of the Form object represents the type of submission, GET or POST, being used by the form.
In Listing 7.261, the method property is used to get the type of method being used by the form. The informMethod() function alerts the user of the method, GET or POST, being used by the form.
<html>
<head>
<title> Using the method property of the Form object</title>
</head>
<body>
<script language="JavaScript">
<!--Hide
function informMethod(){
alert("The form method is:" + document.form1.method);
}
// End Hide --->
</script>
<form name="form1" method="get"> First Name:<input type=text" ... |
Read now
Unlock full access