Advanced Web Designing

 Advanced Web Designing

We have been introduced to basic 

terminologies related to creation of web 

pages. The Hypertext Mark-up Language 

(HTML) is an evolving language, withdifferent versions supporting different 

features. HTML5 is currently used 

because it supports mobile technology.

The major browsers are Google Chrome, 

MozillaFirefox, Microsoft Edge, Safari, 

Opera and Apple support the features of 

HTML5.

1.2 Forms in HTML5

In eleventh standard we have studied 

different controls related to form like text, 

radio, checkbox, submit, reset, select and 

textarea.

These controls are used to collect 

different kinds of user inputs, such as 

contact details like name, address, single 

or multiple options from group of options, 

as well as clearing and submitting data 

etc.

HTML5 has introduced additional 

form controls which can also be used for 

validation purpose.    HTML5 advanced <input> elements

HTML5 introduces a number of new input types. 

Input type Description

<input type="color"> Defines a color picker

<input type="number"> Defines a field for entering a number

<input type="url"> Defines a field for entering a URL.

<input type="image"> Defines an image as a submit button.

<input type="date"> Defines a date picker with the year, month and day

<input type="email"> Defines a field for an e-mail address.  

Some other useful attributes used with <input> are-

1. id : This is used to identify the html element uniquely through the document object 

model.

2. class: It is used to apply CSS style to the individual input element.

Examples :

<!DOCTYPE html> <html>

<head>

<title>Forms in html 5 </title></head>

<body>

<form> Name: <input type="text"autocomplete><br><br>

E-mail:<input type="email" name="email"><br><br>

Date of Inception: <input type="date" name="bday"><br><br>

Office time: <input type="time" name="usr_time"><br><br>

Number of years completed(between 1 and 100): <input type="number" min="1" 

max="100"><br><br>

Office phone number: <input type="tel" name="phone" pattern="[0-9]{2}-[0-9]

{10}" required><br><br>

 Add your homepage:

<input type="url" name="homepage"><br><br>

<input type="image" src="E:/submitbutton.png" alt="click here to submit" >

</form>

</body>

</html> 

1.4 Cascading Style Sheets in HTML5
CSS stands for Cascading Style 
Sheets. CSS describes how HTML 
elements are to be displayed on screen, 
paper, or in other media. CSS saves a 
lot of work. It can control the layout 
of multiple web pages all at once. CSS 
allows you to control the look and feel 
of several pages by changing a single 
source.
CSS Syntax
A CSS rule set contains
a selector and 
a declaration block.
Selector : Selector indicates the HTML 
element you want to style. It could be 
any tag like <h1>, <body> etc.
Declaration Block : The declaration 
block can contain one or more 
declarations separated by a semicolon. 
For the above example, there are two 
declarations:
1. color : yellow;
2. font-size :11 px;
Each declaration contains a property 
name and value, separated by a colon.
Property : A Property is a type of 
attribute of HTML element. It could be 
color, border etc.
Value : Values are assigned to CSS 
properties. In the above example, value 
"yellow" is assigned to color property.
Selector{Property1: value1; Property2: 
value2

Property Use Value Example
Color Changes the color of the text Color name h1{color: maroon}
Background-color To set the background color 
in your webpage
Color name body{background-
color:yellow}
Font-weight Used to bold text bold or 100, 
200…900
p{font-weight:300}
Font-style Used to italicize text Italic, oblique or 
normal
p{font-style:italic}
Text-decoration This property is used to add 
1. strike-through marks 
2. underline 
3. overstrike 
4. to remove underlines from 
links
1. line-through 
2. underline 
3. overline 
4. none
p{text-decoration: 
underline} 
a{text-decoration: 
none}
Text-align This property is use to 
control the horizontal 
alignment of any block-level 
text that are paragraphs, 
tables and other elements
left, right, center 
or justify
h1{text-
align:center}
Font-family This is used to control the 
fonts
Font name p{font-
family:arial

Comments

Post a Comment

Popular posts from this blog

Let's see an example