Web Developer's Virtual Library: Encyclopedia of Web Design Tutorials, Articles and Discussions
 Discussion Forums
 HTML, XML, JavaScript...
 Software Reviews
 Editors,Others...
 Top100
 JavaScript Tutorials, ...
 Tutorials
 ASP, CSS, Databases...
 Discussion List
 FAQ, Roundup, Configure ...
 Authoring
 HTML, JavaScript, CSS...
 Design
 Layout, Navigation,...
 Graphics
 Tools, Colors, Images...
 Software
 Browsers, Editors, XML...
 Internet
 Domains, E-Commerce, ...
 WDVL Resources
  Intermdiate, Tutorials,...
 WDVL
 Discussion Lists, Top 100,...
 Technology Jobs

PDAs
PC Notebooks
Printers
Monitors


WDVL Newsletter

Active Server Pages
JSP/Java Servlets
Microsoft SQL Server
Daily Backup
Dedicated Servers
Streaming Audio/Video
24-hour Support    

jobs.webdeveloper.com

Hiermenus


e-commerce
Partner With Us
Compare Prices
Promotional Products
Memory Upgrades
Data Center Solutions
Promotional Gifts
Laptop Batteries
Dental Insurance
Prepaid Phone Card
Career Education
Car Donations
Free Business Cards
Holiday Gift Ideas
Online Universities
PDA Phones & Cases

Developer Channel
FlashKit.com
JavaScript.com
JavaScriptSource
Developer Jobs
ScriptSearch
StreamingMediaWorld
Web Developer's Journal
Web Developer's Virtual Library
WebDeveloper.com
Webreference
Web Hosts
XMLfiles.com

internet.com
IT
Developer
Internet News
Small Business
Personal Technology
International

Search internet.com
Advertise
Corporate Info
Newsletters
Tech Jobs
E-mail Offers


Heroes Happen Here Launch Events
Attend the upcoming launch of three powerful new products, take a test drive, meet the teams, and leave with promotional copies of Windows Server 2008, Microsoft SQL Server 2008, and Microsoft Visual Studio 2008. Register here. »

 
Install What You Need with Windows Server 2008
Windows Server 2008 is Microsofts most full-featured server operating system yet, so it's ironic that one of its most exciting new features is an install option that cuts out most of the other features. Paul Rubens explores why a Server Core installation makes a great deal of sense in many instances. »

 
Simplify Big Business IT for Small and Midsize Companies
Windows Small Business Server 2008 and Windows Essential Business Server 2008 deliver all-in-one solutions to help fuel growth for customers and partners. »

 
Q&A with Bob Muglia: Senior VP, Server and Tools Division
Bob Muglia, senior vice president, Server and Tools Division, discusses Microsofts new interoperability principles and the steps the company is taking to increase the openness of its products. »

 
Q&A with Lutz Ziob, GM of Microsoft Learning
Lutz Ziob, the general manager of Microsoft Learning, talks about how IT professionals can become certified heroes within their enterprises by getting trained and certified in Windows Server 2008. »
Top 10 Articles
  1. Web Developer's Virtual Library: Encyclopedia of Web Design Tutorials, Articles and Discussions
  2. JavaScript Tutorial for Programmers
  3. Design
  4. JavaScript Tutorial for Programmers - Objects
  5. JavaScript Tutorial for Programmers - JavaScript Grammar
  6. JavaScript Tutorial for Programmers - Versions of JavaScript
  7. Cascading Style Sheets
  8. JavaScript Tutorial for Programmers - Embedding JavaScript
  9. JavaScript Tutorial for Programmers - Functions
  10. Authoring JavaScript
Domain Name Lookup
Search to find the availability of a domain name. Just enter the complete domain name with extension (.com, .net, .edu)

July 26, 1998

Add a Little Style
With the Font-property

In Part 1 we looked at the basics of incorporating CSS into an html file. Part 2 will look at the various font-properties and the proper use of those properties. Attention will be paid to using CSS to replace deprecated elements such as FONT and we'll get into some of the cool stuff, like removing the line under links or adding a hover property.

Using CSS to specify font information is really cool. You can do some really neat things with the font-property, and best of all, you can take your existing html files and without changing the basic coding, you can add style, giving your whole site a new look!

Say you've got a good site, excellent content, but it's a little boring. Just a plain serif font, Normal H elements in all the right places, a few B and EMs thrown in to add emphasis. But boring! Spice it up a tad with a very basic css file!

Simple Style Sheet

<STYLE TYPE="text/css">
<!-- 

BODY	{color		: black;
	background	: white;
	margin		: 50px;
	}

H1	{font-family	: Arial, Helvetica, serif;
	font-size	: x-large;
	color		: #000088;
	background	: #AFEEEE;
	border		: solid;
	}
	
H2	{font-family	: Arial, Helvetica, serif;
	font-size	: large;
	color		: #000088;
	background	: #AFEEEE;
	}	

H3	{font-family	: Arial, Helvetica, serif;
	font-size	: medium;
	color		: #000088;
	background	: #AFEEEE;
	}

	
P, UL	{font-family	: Arial, Helvetica, sans-serif;
	font-size	: small;
	color		: black;
	background	: transparent;
	}	

B	{color		: red;
	background	: transparent;
	}

em 	{color		: #4169E1;
	background	: #B0E0E6;
	font-weight	: bold;
	}
-->
</STYLE>

Notice the Declaration for the BODY element has a margin property. We won't be going into margin properties in part two, but be aware that you can specify margin indentation without having to structure everything inside of tables.

Note: This article has been adjusted to fit the new WDVL design. The margin property has been removed from the inline style sheet so that this page would display properly.- lbc

Absolutely nothing was added to this page besides the style sheet in the header. No class or id attributes were added. The body of the file includes only H, P, B, and EM elements. Pretty cool, huh? Take a look at the original file, sans-style.

Have I got your interest yet? Are you getting excited about the possibilities of CSS? You'll be amazed at how easy it is to design with Style Sheets, so we might as well get started. CSS2 is just coming into it's own, but with the fast pace of developments on the Web, we'll be moving on to new and exciting things before you know it.

Contents:

Summary Part One
Putting Style Sheets in Perspective: Table of Contents
Putting Style Sheets in Perspective:font-family


Up to => Home / Authoring / Style / Sheets


Access FREE HP High-Availability Solutions for Exchange 2007 Tools:
Whitepaper:
Backup and Recovery Best Practices for Microsoft Exchange Server 2007 with HP
Whitepaper:
Best Practices for HP Servers and HP Enterprise Virtual Array in a Microsoft Exchange
Whitepaper:
Optimizing HP Servers with Microsoft SQL Server 2008


Jupiter Online Media: internet.comearthweb.comDevx.commediabistro.comGraphics.com

Search:

Jupitermedia Corporation has two divisions: Jupiterimages and Jupiter Online Media

Jupitermedia Corporate Info


Legal Notices, Licensing, Reprints, & Permissions, Privacy Policy.

Web Hosting | Newsletters | Tech Jobs | Shopping | E-mail Offers