HTML and CSS Reference
In-Depth Information
<head>
<title> Page Title </title>
</head>
<body>
</body>
</html>
Next, add your title so that people will understand the purpose of the web page:
<title> Please Log In </title>
Within the body of the web page, add a form element. I've added both the opening and
closing tags, with an empty line between them, so that I don't forget to close the form
when I'm finished:
<form action=“/form-processing-script” method=“post”>
</form>
Before continuing, you need to know more about the form element and the attributes you
see within the opening tag. Obviously, form begins the element and indicates that you're
creating an HTML form. The action attribute specifies the URL to the server-side script
(including the filename) that will process the form when it's submitted. It's important
that the script with the name you've entered is present on your web server at the location
the URL specifies. In this example, I use the full URL for the script, but you can just as
easily use a relative URL if it makes more sense.
11
CAUTION
Before going live with forms, contact your web hosting provider
and ask whether you can use the hosting provider's scripts or add
your own. You must also determine the URL that points to the
directory on the server that contains the scripts. Some hosting
providers rigidly control scripts for security purposes and won't
allow you to create or add scripts to the server. If that's the case,
and you really need to implement forms on your web pages,
consider searching for a new hosting provider.
The next attribute is method , which can accept one of two possible values: post or get .
These values define how form data is submitted to your web server. The post method
includes the form data in the body of the form and sends it to the web server. The get
method appends the data to the URL specified in the action attribute and most often is
 
Search WWH ::




Custom Search