Learn and solve programming tasks

sponsored

sponsored

Responsive Advertise here call +234 8145146745

GUIDES TO WRITING YOUR FIRST HTML WEBSITE STEP 2


GUIDES TO WRITING YOUR FIRST HTML WEBSITE

WHAT IS HTML?
With HTML you can create your own Website. This tutorial teaches you everything about HTML. HTML is easy to learn - You will enjoy it.
[e.g.]<html></html>

The <head> Tag



Immediately following the opening HTML tag, you'll find the head of the document, which is identified by opening and closing head tags. 

The head of an HTML file contains all of the non-visual elements that help make the page work.
[e.g.]
<html>
<head>your header goes here</head>
</html>


answer the question below by filling in the missing elements!

question 1.0
<
>
   <head> </
>
</html>

The <body> Tag



The body tag follows the head tag.
All visual-structural elements are contained within the body tag. 

Headings, paragraphs, lists, quotes, images, and links are just a few of the elements that can be contained within the body tag.

Basic HTML Structure:
<html>
<head>
</head>
<body>
</body>
</html>

question 1.1

Rearrange the code to create a basic HTML document structure:
Note when writing your answer specify what which question you are answering
i.     </body>
ii.    </html>
iii.   <body>
iv.   <html>
v.    <head></head> 

a.    ii, v, iii, i.
b.    iii, i, ii, v,
c.    i, ii, iii, i.


CREATING YOUR FIRST HTML PAGE

HTML files are text files, so you can use any text editor to create your first webpage. 
There are some very nice HTML editors available; you can choose the one that works for you. For now let's write our examples in Notepad.




The HTML File



Add the basic HTML structure to the text editor with "This is a line of text" in the body section.



<html>
<head>
</head>
<body>
This is a line of text.
</body>
</html>



Don’t forget to save the file. HTML file names should end in either .html or .htm

In our example, the file is saved as first.html 

When the file is opened, the following result is displayed in the web browser:

question 1.2 


What is the correct extension for HTML files?

a.  .exe
b.  .html
c .txt
d.    .css


The <title> Tag



To place a title on the tab describing the web page, add a <title> element to your head section:

<html>
<head>
<title>
first page</title> </head>
<body>
This is a line of text.
</body>
</html>
This will produce the following result:
The title element is important because it describes the page and is used by search engines.


question 1.3
Where should you put the title tag?

A.   After the closing html tag
B.   Between the body tags
C.    Before the html tag
D.   Between the head tags

EXAMPLE 1
<!DOCTYPE html>
<html>
<head>
<title>Page Title</title>
</head>
<body>

<h1>This is a Heading</h1>
<p>This is a paragraph.</p>

</body>
</html>

THIS IS HOW YOUR SETUP WILL LOOK LIKE

THIS WILL BE USED TO BEATIFY YOUR FIRST PROJECT BUT FIRST YOU WILL NEED TO KNOW SOME BASIC CSS

body {
    background-color: lightblue;
}
h1 {
    color: white;
    text-align: center;
}
{
    font-family: verdana;
    font-size: 20px;
}


TO BE CONTINUED CHECK BACK IN FEW MINUTES

No comments:

Post a Comment