Style-Sheets
  Home arrow Style-Sheets arrow Page 4 - Understanding Style Sheets (Part 1)
Dev Shed Forums 
Administration  
Apache  
BrainDump  
DHTML  
Flash  
Java  
JavaScript  
Multimedia  
MySQL  
Oracle  
Perl  
PHP  
Practices  
Python  
Reviews  
Security  
Style-Sheets  
Web Services  
XML  
Zend  
Zope  
Forums Sitemap 
IBM® developerWorks 
Dedicated Servers 
E-Commerce Hosting 
Linux Web Hosting 
Managed Hosting 
Small Business Hosting 
Download TestComplete 
VPS Hosting 
Weekly Newsletter

 
Developer Updates  
Free Website Content 
IBM Rational Software Development Conference
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
STYLE-SHEETS

Understanding Style Sheets (Part 1)
By: icarus, (c) Melonfire
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 4 stars4 stars4 stars4 stars4 stars / 31
    2000-09-27

    Table of Contents:
  • Understanding Style Sheets (Part 1)
  • Into The Light
  • More Pseudo-Gibberish
  • The Colour Of My Eyes
  • Playing With Type
  • Adding A Little Style

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
     
    ADVERTISEMENT

    A high performance database engine using optimized data access for all development environments including Delphi, Visual Studio .NET, Visual Basic, Visual FoxPro. and more. Learn More

    Understanding Style Sheets (Part 1) - The Colour Of My Eyes
    (Page 4 of 6 )

    Now that all the theory's out of the way, how about actually getting down with some of the basic CSS properties available?First on the list
    is the "color" property. As you've seen in the examples above, this property controls the foreground colour of an HTML element, and comes in very handy when you need to change the colour of different blocks of text. The example below turns all italicized text blue.

    <HEAD>
    <STYLE TYPE="text/css">
    I {color: blue)
    </STYLE>
    </HEAD>

    CSS offers a number of different ways to specify the colour value here. The simplest is to use one of the sixteen pre-defined colour names available - aqua, black, blue, fuchsia, gray, green, lime, maroon, navy, olive, purple, red, silver, teal, white, and yellow. You can also specify a hexadecimal colour combination by prefixing it with a #I {color:#0000FF) or a combination of RGB values in absolute or percentage terms, like this:I {color: rgb (0, 0, 255))I {color: rgb (0%, 0%, 100%))Following close on the heels of "color" comes "background-color", which controls the background colour of an HTML element.

    <HTML>
    <HEAD>
    <STYLE TYPE="text/css">
    .blue {color: cyan; background-color: #FF8000}
    .green {color: lime; background-color: black}
    </STYLE>

    </HEAD>

    <BODY>

    <P CLASS="blue">
    Oooh...you have beautiful eyes!
    <P CLASS="green">
    I know. But you aren't too bad yourself.

    </BODY>
    </HTML>

    Keep looking at that combination, and you'll make some eye surgeon very, very rich!

    More Style-Sheets Articles
    More By icarus, (c) Melonfire


     

       

    STYLE-SHEETS ARTICLES

    - What is CSS?
    - The Power of CSS
    - Understanding Style Sheets (part 2)
    - Understanding Style Sheets (Part 1)




    © 2003-2008 by Developer Shed. All rights reserved. DS Cluster 6 hosted by Hostway