www.freewebsite.0nyx.com
You are here: Home >> DHTML tutor >> Lesson 1 www.freewebsite.0nyx.com - Free Website
 
Site guide
 HOME
 SITE MAP
 
Free tutorials
 Free Flash tutor
 Free HTML tutor
 Free JavaScript tutor
 Free DHTML tutor
 
Free Online Tools
 Color Picker
 MouseOver buttons
 Menus : Dropdown
 Page effects
 Scrollbar
 
More stuff
 Free sub-domains
 Make money : Banners
 Increase traffic
 Improve your website


Become a member become a member      Member's Log-in

DHTML LESSON 1

Make a header with some text in it:

<H2>Header 1</H2>
You should have this:

Header



Now if you wanted to make the header green, you would do this:

<H2><FONT color="green">Header 1</FONT></H2>
You'd get something like this:

Header 1



Now suppose you wanted to make every header on your page green.

Do you have to use the font tag every time? Thanks to DHTML or CSS(for now), the answer is no.

Remove the font tags from your page and your notepad should look something like this:

<HTML>
<HEAD>
<TITLE></TITLE>
</HEAD>
<BODY>

<H2>Header 1</H2>

</BODY>
</HTML>


Add style tags to your webpage:

<HTML>
<HEAD>
<TITLE></TITLE>

<STYLE TYPE="text/css">

</STYLE>

</HEAD>
<BODY>

<H2>Header 1</H2>

</BODY>
</HTML>


Now add the element H2 in the style tags and a pair of curly brackets.

<HTML>
<HEAD>
<TITLE></TITLE>

<STYLE TYPE="text/css">
 H2 {} 
</STYLE>

</HEAD>
<BODY>

<H2>Header 1</H2>

</BODY>
</HTML>


Now make every H2 element on the page green.

<HTML>
<HEAD>
<TITLE></TITLE>

<STYLE TYPE="text/css">
 H2 {color:green} 
</STYLE>

</HEAD>
<BODY>

<H2>Header 1</H2>

</BODY>
</HTML>
That's there is to it. Go to the next chapter to learn more about CSS properties and the class element. If you get this chapter, the next chapter is a piece of cake.

< < Back     Next > >
Freewebsite: Web design tutorials for the rest of us
Lessons:      Intro 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20

 
Praise for freewebsite
   "These tutorials are written in such simple language and they're so much fun. They're simply the best." - Mike

   "Just wanted to drop you a line to say thank you. I created my website within a month after reading your tutorials and now I make thousands with it." - Ken