E-mail List Archives
Using the Clip CSS property to visually hide text
From: Birkir R. Gunnarsson
Date: Nov 15, 2012 3:36PM
- Next message: Bryan Garaventa: "Re: Using the Clip CSS property to visually hide text"
- Previous message: Angela French: "Re: issue with onChange in dynamic select list"
- Next message in Thread: Bryan Garaventa: "Re: Using the Clip CSS property to visually hide text"
- Previous message in Thread: None
- View all messages in this Thread
Hi guys
Uptil now I have always seen and recommended manually positioning
hidden text off-screen using CSS (examples on WEbaim site and many
other places).
I was reading a Yahoo! developer blog on forms and labels at
http://developer.yahoo.com/blogs/ydn/posts/2012/11/form-labels-visible-and-hidden/
and they recommend a different way, the clip property of CSS
The code goes:
Class boscure:
.obscure {
position: absolute !important;
clip: rect(1px 1px 1px 1px); /* IE6, IE7 */
clip: rect(1px, 1px, 1px, 1px);
}
This seems to be neat and quick, but I wonder if it has any
disadvantages or does not work for some reason, as I have never seen
this method before.
Cheers
-B
- Next message: Bryan Garaventa: "Re: Using the Clip CSS property to visually hide text"
- Previous message: Angela French: "Re: issue with onChange in dynamic select list"
- Next message in Thread: Bryan Garaventa: "Re: Using the Clip CSS property to visually hide text"
- Previous message in Thread: None
- View all messages in this Thread