|
Posted by rf on 09/21/05 16:40
the idiot wrote:
> #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.
Navigation:
[Reply to this message]
|