FORM STRUCTURE

Image
  FORM STRUCTURE <form>: form controls live inside a <form> element .This element should always carry the action attribute and will usually have a method and ad id attribute too. action: Every form element requires an action attribute. Its value of the URL for the page on the server that will receive the information in the form when it is submitted> method: The form can be sent using one of the following methods: get or post. With the get method, the values from the form are added to the end of the URL specified in the action attribute. With the  Post method, the values   are sent in what is  known as HTTP headers.  <input>: The <input> element creates several different  form controls. The type attribute's value determines what kind of input they will be creating. type="text': When the type attribute has a value of text, it creates single-line text  input. name: When users enter information into a form, the server contro...

Basic structure of HTML


                                              

Basic Structure of HTML

Coding

You can see the HTML code for the page below. Don't worry
about what the code means yet. We start to look at it in more 
details on the next blog. Note that the HTML code is in blue,
and the text you see on the result part is in black.


<html>
 <body>
    <h1>This is the main Heading</h1>
    <p>This text might be an introduction to rest of the web page.
     And if the page is a long one it might be split up into several
     sub-headings.</p>
    <h2>This is a sub-heading</h2>
    <p>Many long articles have sub-headings so to help you follow 
    the structure of what is being written. There may even 
    sub-sub-headings (or lower-level headings).<p>
    <h2>Another Sub-heading</h2>
    <p>Here you can see another sub-heading.</p>
  </body>
</html>

Explanation

The HTML code (in blue) is made up of characters that live inside
angled brackets-these are called HTML elements. Elements are
usually made up of two tags: an opening tag and a closing tag. (the
closing tag has an extra forward slash in it.) Each HTML element
tells the browser something about the information that sits between 
its closing tag and opening tag.

Result



Comments

Post a Comment

Popular posts from this blog

Ch-Heading Tags (blog 3)

Introduction to HTML