suckerfish elastic width thing

T

the idiot

http://www.htmldog.com/articles/suckerfish/dropdowns/example/

anyway i was looking at this because the elasticity bit interests me
and i was looking at the css which is where i get a bit confused..

for instance.....

#nav a {
display: block;
width: 10em;
w\idth: 6em;
color: #7C6240;
text-decoration: none;
padding: 0.25em 2em;
}

what does the w\idth bit do - is it a hack or something?
pardon my ignorance but i am still trying to learn as fast as i can
mainly through reverse engineering

thanks in advance
 
R

rf

the said:
#nav a {
display: block;
width: 10em;
w\idth: 6em;
color: #7C6240;
text-decoration: none;
padding: 0.25em 2em;
}

what does the w\idth bit do - is it a hack or something?
pardon my ignorance but i am still trying to learn as fast as i can
mainly through reverse engineering

It's a way of "commenting" out something that you don't want without going
to the trouble if using the /* */ comment construct? If so, it's a bad way.
w\idth is not a valid property so gets ignored, well it *should* get
ignored.[1]

However that said I often use a z to cheap and nastily "deactivate"
properties or attributes. For example
<div zclass="whatever">
temporarily disables the class attribute for that div with a single
keystroke.

I only do this where I know it *will* be ignored, that is in the couple of
browsers I use for alpha testing.

Never leave such artifacts in a production or even a beta page. You don't
know what the users/clients browser will do with it.

[1] At least on browser, obsolete Netscape 4.7, will ignore the entire CSS
rule if one single property is invalid. We are relying on the browsers error
correction here.

Cheers
Richard.
 
W

Wÿrm

"the idiot" <[email protected]> kirjoitti
viestissä:[email protected]...

#nav a {
display: block;
width: 10em;
w\idth: 6em;
color: #7C6240;
text-decoration: none;
padding: 0.25em 2em;
}

what does the w\idth bit do - is it a hack or something?

If I recall right, in this case it "hides" width: 6em; from MS IE 5.5 and
5.0. For IE 5.0 and 5.5 width:10em; is last thing they see, for IE 6em; is
what IE 6.0 sees. Usually this is one way to get things work on IE 5.0 and
5.5 for some of their broken box model bug that were fixed for IE 6.0.
 
T

the idiot

the idiot said:
http://www.htmldog.com/articles/suckerfish/dropdowns/example/

anyway i was looking at this because the elasticity bit interests me
and i was looking at the css which is where i get a bit confused..

for instance.....

#nav a {
display: block;
width: 10em;
w\idth: 6em;
color: #7C6240;
text-decoration: none;
padding: 0.25em 2em;
}

what does the w\idth bit do - is it a hack or something?
pardon my ignorance but i am still trying to learn as fast as i can
mainly through reverse engineering

thanks in advance
thanks for the replies.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,767
Messages
2,569,570
Members
45,045
Latest member
DRCM

Latest Threads

Top