iEntry 10th Anniversary Forum Rules Search
WebProWorld
Register FAQ Calendar Mark Forums Read
Webmaster Resources Discussion Forum Sitemaps and robots and logfiles -- Oh My! If you have any questions, comments, concerns and/or ideas about the tools currently available to webmasters to make their lives... 'easier'. Here's where you need to be. Know of a good tool? Post it here. Got something funny in your logfiles? Maybe we can help.

Share Thread: & Tags

Share Thread:

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 09-18-2008, 04:55 AM
jollymoon's Avatar
WebProWorld New Member
 
Join Date: Oct 2005
Location: Atlanta
Posts: 14
jollymoon RepRank 0
Default *HTML CSS Code Question

This is silly.

I just spent three hours wading through CSS related sites, HTML Cheat Sheets, Typography junk, etc.

What is the *HTML code in a CSS external sheet? *HTML #nav { BACKGROUND: #2F3F3F} or
* HTML .clearfix { HEIGHT: 1%}

This is driving me crazy. Shouldn't be that hard to find an answer.

HELP
Reply With Quote
  #2 (permalink)  
Old 09-18-2008, 05:06 AM
jollymoon's Avatar
WebProWorld New Member
 
Join Date: Oct 2005
Location: Atlanta
Posts: 14
jollymoon RepRank 0
Default Re: *HTML CSS Code Question

Almost found something?

CSS Cheat Sheet (V1) - Cheat Sheets - Added Bytes
lists a cheat sheet * as "all elements"

uhh, ok?
Reply With Quote
  #3 (permalink)  
Old 09-18-2008, 02:59 PM
Dubbya's Avatar
WebProWorld 1,000+ Club
WebProWorld MVP
 
Join Date: Nov 2006
Location: Steinbach, Manitoba, Canada
Posts: 1,300
Dubbya RepRank 4Dubbya RepRank 4Dubbya RepRank 4Dubbya RepRank 4Dubbya RepRank 4
Default Re: *HTML CSS Code Question

"* HTML" is a CSS hack which is used to cater code specifically to IE6 and below. It allows developers to take advantage of a known bugs in the browser software.

CSS Hacks can be applied to any web page element that CSS can alter.

In this case, if I want negative padding applied to a named div when a page is displayed in IE6 or below, I might do this:
HTML Code:
* html #testdiv {padding-bottom:-2px;}
Firefox, Opera and Safari browsers would ignore the hack so, for them I'd code in the standard fashion.

HTML Code:
div#testdiv {padding:10px;}
* html #testdiv {padding-bottom:-2px;}
The hacked CSS should always be placed after standard code so that the targeted browser applies the hack.

For more info on CSS Selectors and hacks, check out:
CSS Hacks

enjoy!
Reply With Quote
  #4 (permalink)  
Old 09-20-2008, 01:31 PM
sheanhoxie's Avatar
WebProWorld New Member
 
Join Date: Sep 2008
Location: San Diego, CA
Posts: 1
sheanhoxie RepRank 0
Default Re: *HTML CSS Code Question

Yea IE hack, best not to use a hack though, you should use a separate stylsheet for IE instead of hacks.

To do: Create two stylesheets, one for FF one for IE. Call the FF stylesheet first in your head, then call your IE stylesheet using this code:
Code:
       <!--[if IE]>
		<link rel="stylesheet" href="ie_stylesheet.css" type="text/css" />
	<![endif]-->
This allows you to create one stylesheet that works for FF/Opera browsers, and then you can tidy up any quirks in IE by overriding with your IE stylesheet and still have w3 compliant code
Reply With Quote
Reply

  WebProWorld > Webmaster, IT and Security Discussion > Webmaster Resources Discussion Forum

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
rel= 'external' tag in HTML code tricker Search Engine Optimization Forum 1 08-13-2007 03:22 PM
Simple HTML code abalfazl Graphics & Design Discussion Forum 4 08-07-2006 09:00 AM
Will code HTML for food TrafficProducer Web Programming Discussion Forum 6 01-18-2005 05:50 AM
compress html code asimkhaliq Graphics & Design Discussion Forum 1 06-26-2004 09:50 PM


All times are GMT -4. The time now is 09:25 PM.



Search Engine Optimization by vBSEO 3.3.0