WebDeveloper.com ®: Where Web Developers and Designers Learn How to Build Web Sites, Program in Java and JavaScript, and More!   
Web Developer Resource DirectoryWebDev Jobs  
Animated GIFs
CSS
CSS Properties
Database
Design
Flash
HTML
HTML 4.01 Tags
JavaScript
.NET
PHP
Reference
Security
Site Management
Video
XML/RSS
WD Forums
 Client-Side
  Development

    CSS
    Graphics
    HTML
    JavaScript
    XML
    Dreamweaver/FrontPage
    Multimedia
    Web Video
    General
    Accessibility

 Server-Side
  Development

    ASP
    Perl
    PHP
    .NET
    Java
    SQL
    Other

 Web Development
  Business Issues

    Business Matters
    Website Reviews

 E-Commerce
    Domain Names
    Search Engines

 Etc.
    Computer Issues
    Forum Software
    Feedback
    The Coffee Lounge



Script Downloads
Disable Form Buttons

Featured: July 23, 2008
Description: This script will disable your submit button in order to prevent multiple form submissions. Easy to implement.

Get Script

Hosting Search
Unix   Windows
PHP   Webmail

Sign up for the free WebDeveloper E-mail newsletter!


JupiterWeb Commerce
Partners & Affiliates
Partner With Us
Website Load Testing
Web Hosting Directory
KVM Switches
Memory
Compare Prices
Home Improvement
Corporate Gifts
Prepaid Phone Card
Promos and Premiums
Free Business Cards
Promote Your Website
Phone Cards
Shop Online
PDA Phones & Cases

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

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

Just because Web sites are easy to build these days, that doesn't mean it's easy to build a quality Web site that meets your business objectives.

Before developing your next Web site, or redesigning an existing site, download this Internet.com eBook to guide you through the process and plan your project, whether you're developing a site in-house or outsourcing the project.
Register now for your free Internet.com membership to download your complimentary eBook. Membership will also give you access to:

eBook library         Whitepapers         Webcasts
Newsletters         WinDrivers

CSS Simplifies Your Life
Part 1

by Scott Clark
First published February 1998

Old hat? Then why aren't you using them?

Last month we looked at Dynamic HTML and how to use it. The knowledge of cascading style sheets greatly facilitates the use of Dynamic HTML, and many of our readers asked for more info on CSS to help them get started.

By now most of us are aware that cascading style sheets can be used to control style and layout of a Web page, or build a style sheet "standard" that can be repeatedly used on a Web site. This "template" approach to designing a site enables developers to create a consistant look for corporate documents, while keeping style separate from content.

Want to change the way a page looks? Simply change the style sheet once and all the pages which use that style are instantly changed as well. So why haven't more people been using style sheets? Aside from the fact that only the 4+ browsers (Navigator 4+ and MSIE4+) can use them, perhaps it's because folks simply don't know how useful they can be, and how simple they are to use.

The use of CSS can be seen on many of today's leading Web sites, including WebReference.com and CNET, among others. If you visit the sites using one of the aforementioned CSS-capable browsers, you're seeing CSS in action. On the page you're currently reading, for instance, all of the font styles and headlines are controlled by style sheets instead of FONT tags. And the pages actually look almost identical under both MSIE4 and Netscape4, as the basic style sheet format is supported by both of them.

If you're wondering whether the same CSS specification is used by both browsers, the answer is yes ... almost. Although CSS will work for either browser, each has its own methods of utilizing dynamic HTML and style sheets. Netscape is favoring the use of JSS, or JavaScript style sheets, which are characterized by the TYPE="text/javascript" parameter of the STYLE tag. The format for the CSS used by JavaScript SS is different as well.

Likewise, Microsoft has made it extremely easy to use CSS to dynamically create dynamic effects. For instance, if you are using MSIE4, run your mouse over the words "Old hat? Then why aren't you using them?" at the top of this page. That little effect uses one line of code:

<H4 onMouseOver="this.style.color='blue'" onMouseOut="this.style.color='gray'">

Most CSS techniques, however, may be used for both browsers. Did you notice that the hyperlinks on this page are not underlined? One line in the Style Sheet did that for the whole page, using the "text-decoration" property:

A:link { background: white; color: blue; text-decoration: none; }

If you're using an older version of Netscape or MSIE to view this page, it simply shows plain, unformatted text. Or rather, if the text is enclosed by a normal HTML tag, the normal effects of the tag are what shows up in the browser.

  [ CSS Simplifies Your Life:
Part 2 > ]




Acceptable Use Policy

JupiterOnlineMedia

internet.comearthweb.comDevx.commediabistro.comGraphics.com

Search:

Jupitermedia Corporation has two divisions: Jupiterimages and JupiterOnlineMedia

Jupitermedia Corporate Info


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

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