Complete HTML coding for kids chapter 2
Table of Contents
ToggleComplete HTML coding for kids chapter 2
HTML FORMS
In Html form Tag is used to create or design a simple form under body element. It has a certain facility to put data with an interactive layout.
It has buttons and several fields which has fields such as input text box Input Password box, input radio button select box message text area, and so on.
Labels tag are names of form to be designed in the form of the tag.
Form Coding in HTML
<html>
<head>
<title>Form Tags</title>
</head>
<body>
<form >
<label>Name</label> <input type=”text” value=”” placeholder=”Enter your name” /> <br><br>
<label>Password</label> <input type=”password” name=”” /> <br><br>
<label>Gender</label> <input type=”radio” name=”gender” id=”male” /><label for=”male”>Male</label>
<input type=”radio” name=”gender” id=”female”><label for=”female”>Female</label> <br><br>
<label>Hobbies</label> <input type=”checkbox” name=”hobby” id=”music” />
<label for=”music”>Music</label> <input type=”checkbox” name=”hobby” id=”football”><label for=”football”>Football</label> <br><br>
<label>Message</label> <textarea rows=”10″ cols=”60″>type your message</textarea> <br><br>
</form>
</body>
</html>
Form is designed under <body>…</body> tag with <form>…</form> tag
Labels are the name of the form to be desplay in page .It is to be under <label>…</label>tag
Input type is the type of data in the form to be interacted. such asĀ
<input type=”text”> which is used for name or any such similar field.
<input type=”password”>
it is used for password to be given by user.
<input type=”radio”> it us used for radio button to be clicked by the userĀ
<input type=”checkbox”>
checkbox is given to select the box from the list .
<br> tag is given to give break between lines so each form field shows on different line.
name=”” is given specify the name of the input type and id to make it unique.
Ā
Iframe tag
<iframe> tag is used under <body> tag to show the other website view in page or same website page view.he <iframe> tag specifies an inline frame. An inline frame is used to embed another document within the current HTML document.
Ā
The iframe in HTML stands for Inline Frame. The ā iframe ā tag defines a rectangular region within the document in which the browser can display a separate document, including scrollbars and borders. An inline frame is used to embed another document within the current HTML document.
<html>
<head>
<title>Iframe Tag</title>
</head>
<body>
<iframe src=”https://www.thevistaacademy.com/” align=”left” frameborder=”1″ width=”500px” height=”500px”></iframe>
</body>
</html>
Font properties in HTML
- We will know about three properties in the Font tag .
- color
- sizeĀ
- face
<html>
<head>
<title>First Web Page</title>
</head><body>
<h1><font color=”red” size=”7″ face=”arial,verdana”>this heading 1</font></h1>
<h2><font color=”green” size=”6″ face=”arial,verdana”>this heading 2</font></h2>
<h3><font color=”blue” size=”5″ face=”arial,verdana”>this heading 3</font></h3>
<h4><font color=”purple” size=”4″ face=”arial,verdana”>this heading 4</font></h4>
<h5><font color=”#fd521e” size=”3″ face=”arial,verdana”>this heading 5</font></h5>
<h6><font color=”#be2276″ size=”2″ face=”arial,verdana”>this heading 6</font></h6>
</body>
</html> - Ā
this tag is used to embaded video in HTML from the loacation where u have video file .
we have to know the extention of the video in this code we are usign mp4 video to show a embaded video to run on browser.
<html>
<head>
<title>Video Tag</title>
</head>
<body>
<video controls >
<source src=”peace.mp4″ type=”video/mp4″ />
</video>
</body>
</html>