Sunday, July 9, 2017

HSC ICT (Chapter-04, Lecture-05)


11) Background

The background attribute of the <body> tag specifies the location of the image file to be displayed in the background of the web page. It takes an absolute or a relative path of the image file (the files with an extension .gif, .jpeg) that will be used as the background of the document. The image file will be tiled across the document.
Example
<BODY BACKGROUND="filename.gif"> </BODY>
Example: An HTML document attribute.html that shows the use of attributes with the <BODY> tag
<HTML>
<HEAD>
<TITLE>
Use of Attributes with the Body Tag
</TITLE>
</HEAD>
<BODY BGCOLOR="yellow">
<BODY TEXT="red">
TOPMARGIN ="50"
LEFTMARGIN="50">
Your document text will be indented 50 pixels from the left hand and 50 pixels from the top of the page.
The body color is yellow and text color is red.
</BODY>
</HTML>

                                Figure : Viewing HTML document in browser- attribute.html
12) Heading <H1>.............<H6> 
The purpose of the heading tag is to indicate different heading levels in a document. HTML has six header tags <H1>, <H2>...........<H6> used to specify section headings. Text with header tags is displayed in larger and bolder fonts than the normal body text by a web browser. Every header leaves a blank line above and below it when displayed in browser. Let‟s write the following HTML code to see how the heading levels will look on a browser.
<HTML>
<HEAD>
<TITLE>
Section Heading
</TITLE>
</HEAD>
<BODY>
<H1> Section Heading Level 1 </H1>
<H2> Section Heading Level 2 </H2>
<H3> Section Heading Level 3 </H3>
<H4> Section Heading Level 4 </H4>
<H5> Section Heading Level 5 </H5>
<H6> Section Heading Level 6 </H6>
</BODY>
</HTML>
Now save the file as headings.html and open the file in your browser.
Figure Six heading levels show you what you would see.

 
Share:

0 comments:

Post a Comment

Recent Posts

Unordered List

  • Lorem ipsum dolor sit amet, consectetuer adipiscing elit.
  • Aliquam tincidunt mauris eu risus.
  • Vestibulum auctor dapibus neque.

Pages

Theme Support

Need our help to upload or customize this blogger template? Contact me with details about the theme customization you need.