DRÄ Studio

Pixel pushing and pencil shavings

Home Blog Projects Wallpapers Themes Fonts

Blog

Hiding via CSS

Posted on Friday, May 16th, 2008 under Code | No comments

I am in the middle of some research for my Graphic Web Design course and I am in search of an article I thought I had read a while ago.

If I am remembering correctly, it outlined the pros and cons of using the two typical methods of hiding content using CSS styles.

Option #1:

selector { display:none; }

Option #2:

selector { text-indent: -9999px; }

The second is a little trick I first saw Zeldman use, but I know the article I am thinking of talked about how it can cause problems when using a right-aligned layout (which I have experienced first-hand), but I can’t seem to find it again.

Anyone else know how to use Google search better than me? ;)

Related Posts:

Should I write HTML with single or double quotes?
By point of personal preference, I am always encouraging students to be consistent with their usage of capitalization, indentations and quotation mark usage. Code should be as clean as possible and consistency throughout is an easy way to catch small errors or discrepancies. In some cases, however, you can actually find valid reasoning behind those personal ...
Google Chrome on the Mac
It has been a few days now since Ars Technica announced Google's Developer Preview for Chrome on the Mac and I have been loving every minute of it. While I do miss the robust plugin architecture of Firefox and the slickness of Safari 4's "Top Sites", Chrome's speed trumps all. New tabs and windows are quick ...
Star Eyed
Well blow my mind away! Apparently Adobe Illustrator does have a sweet little keyboard command for increasing or decreasing the inner radius of a star. Here is a quick review of all of the commands I use when drawing my stars: Up-arrow / down-arrow : Use these to increase/decrease (respectively) the number of points on the ...
Chrome for Mac – Now with Extensions
The last couple of weeks I have been going back and forth between Firefox and Safari as my default web browser, trying to appreciate their full-featured nature over the fact that they are both so sluggish in comparison to the lovely Chrome Beta. Thankfully, Google announced support for two of the things that have really ...
Adding More Coda Books – Version 1
After Sitepoint showed us all how easy it is to add custom references to the "Books" section of Coda (using their excellent HTML and CSS references as examples), I began my search for even more handy code guides with which to fill out that big empty gray space at Command+6. Jon Hicks had some good stuff ...

Write a comment

Your e-mail address is never published nor shared. Required fields are marked *

*

*

:

:

 

Back to Top