Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Web Programming > CSS > CSS Cascading Style Sheets
Password Reminder
Register
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
CSS Cascading Style Sheets All issues relating to Cascading Style Sheets (CSS).
Welcome to the p2p.wrox.com Forums.

You are currently viewing the CSS Cascading Style Sheets section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developersí questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old January 20th, 2006, 06:06 AM
Friend of Wrox
Points: 8,019, Level: 38
Points: 8,019, Level: 38 Points: 8,019, Level: 38 Points: 8,019, Level: 38
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2005
Location: Mauchline, East Ayrshire, Scotland
Posts: 1,525
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to crmpicco Send a message via AIM to crmpicco Send a message via MSN to crmpicco Send a message via Yahoo to crmpicco
Default purpose of hash in CSS style

Code:
#load {position: absolute;top: 50;left: 0;height: 200%;width: 100%;background-color: #f5f5f5;}
.loading {font-family:Verdana, Arial, Helvetica, sans-serif; font-size:-2;"}
What is the purpose of the hash?

Regards,
Picco

www.crmpicco.co.uk
__________________
_______________________
Ayrshire Minis - a Mini E-Community
http://www.ayrshireminis.com
http://www.crmpicco.co.uk
Reply With Quote
  #2 (permalink)  
Old January 20th, 2006, 09:32 AM
richard.york's Avatar
Wrox Author
Points: 5,506, Level: 31
Points: 5,506, Level: 31 Points: 5,506, Level: 31 Points: 5,506, Level: 31
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Camby, IN, USA.
Posts: 1,706
Thanks: 0
Thanked 5 Times in 5 Posts
Default

The hash is an id selector. So, somewhere in the body there is an id name of "load" like so:

<div id='load'>

Where as the dot is a class selector, and references an element with a class name of "loading" like so:

<div class="loading">

Regards,
Rich

--
[http://www.smilingsouls.net]
Mail_IMAP: A PHP/C-Client/PEAR solution for webmail
Author: Beginning CSS: Cascading Style Sheets For Web Design
Reply With Quote
  #3 (permalink)  
Old January 20th, 2006, 09:52 AM
planoie's Avatar
Friend of Wrox
Points: 16,481, Level: 55
Points: 16,481, Level: 55 Points: 16,481, Level: 55 Points: 16,481, Level: 55
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2003
Location: Clifton Park, New York, USA.
Posts: 5,413
Thanks: 0
Thanked 16 Times in 16 Posts
Default

In CSS you can identify what a style applies to in 3 ways (from a basic level):

1. Tag name: Type just the letters of the tag the style applies to:
    TD{
       background-color: #FF0000;
    }

2. Class name. Identify the tag's class that the style applies to. For this you need to specify the class in the element's markup (<TD class="RedBG">):
    .RedBG{
       background-color: #FF0000;
    }

3. Object ID. Identifies a specific element by ID to which the style applies. For this you specify the tags ID attribute (<span id="PageHeader">):
    #PageHeader{
       font-size: 36px;
       color: #00FF00;
    }
Usually, you would have only one element with that ID on the page otherwise you'd have a ID conflict that could cause other problems.

You can combine style identifiers to be more specific:

TABLE#MasterLayout{}
TD.Header{}

and chain them together to create complex styles with simple style syntax:

TABLE#MasterLayout TD.Header{}

In this case, the "TD.Header" style will be different for TD tags with the "Header" class when they exist under a table with the "MasterLayout" ID.

-Peter
Reply With Quote
  #4 (permalink)  
Old February 13th, 2006, 06:56 AM
Friend of Wrox
Points: 8,019, Level: 38
Points: 8,019, Level: 38 Points: 8,019, Level: 38 Points: 8,019, Level: 38
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2005
Location: Mauchline, East Ayrshire, Scotland
Posts: 1,525
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to crmpicco Send a message via AIM to crmpicco Send a message via MSN to crmpicco Send a message via Yahoo to crmpicco
Default

excellent, thank you both

www.crmpicco.co.uk
Reply With Quote
  #5 (permalink)  
Old March 15th, 2017, 06:41 AM
Registered User
Points: 12, Level: 1
Points: 12, Level: 1 Points: 12, Level: 1 Points: 12, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Mar 2017
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

CSS stands for Cascading Style Sheets. CSS was invited by Hakon Wium Lie on October 10, 1994 and maintained through a group of people within the W3C called the CSS Working Group. The CSS Working Group creates documents called specifications. When a specification has been discussed and officially ratified by W3C members, it becomes a recommendation. css tutorials pdf CSS is used to define styles for your web pages, including the design, layout and variations in display for different devices and screen sizes. CSS describes how HTML elements are to be displayed on screen, paper, or in other media. CSS is easy to learn and understand but it provides powerful control over the presentation of an HTML document. Most commonly, CSS is combined with the markup languages HTML or XHTML.

CSS files are termed “cascading” stylesheets because of two reasons: one stylesheet can cascade, or have influence over, multiple pages. Similarly, many CSS files can define a single page. We can apply CSS in 3 ways such as Internal CSS, Inline CSS and External CSS.

CSS is designed primarily to enable the separation of document content from document presentation, including aspects such as the layout, colors, and fonts. This separation can improve content accessibility, provide more flexibility and control in the specification of presentation characteristics, enable multiple HTML pages to share formatting by specifying the relevant CSS in a separate .css file, and reduce complexity and repetition in the structural content. Separation of formatting and content makes it possible to present the same markup page in different styles.https://en.wikipedia.org/wiki/Cascading_Style_Sheets
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
css and style atribute equivalents nerssi Javascript 2 April 11th, 2007 05:26 AM
assigning a css style sheet from an element miguel XSLT 7 August 8th, 2004 01:21 PM



All times are GMT -4. The time now is 08:13 PM.


Powered by vBulletin®
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.