From: Hans-Georg Michna on 3 Apr 2010 04:40 On Fri, 02 Apr 2010 20:09:07 -0400, David Mark wrote: >Chris F.A. Johnson wrote: >> On 2010-04-02, David Mark wrote: >>> Scott Sauyet wrote: >>>> At the risk of actually answering a rhetorical question, I'll bite. >>>> It should tell you that this DIV element is of the class "toolbox". >>> Which tells you nothing at all. >> Only if you don't know what a [toolbox] is. >Even a "toolbox" could mean anything in the context of a class >attribute. The mind reels at the possibilities. "When I use a word," Humpty Dumpty said in rather a scornful tone, "it means just what I choose it to mean---neither more nor less." "The question is," said Alice, "whether you can make words mean so many different things." "The question is," said Humpty Dumpty, "which is to be master---that's all." Alice was too much puzzled to say anything, so after a minute Humpty Dumpty began again. "They've a temper, some of them---particularly verbs, they're the proudest---attributes you can do anything with, but not verbs---however, I can manage the whole of them! Impenetrability! That's what I say!" [I apologize for altering one word. Hans-Georg]
From: Hans-Georg Michna on 3 Apr 2010 06:06 On Fri, 2 Apr 2010 14:22:19 -0700 (PDT), Antony Scriven wrote: >In my experience using classes for semantic purposes can help >with large projects (especially collaborations). So if this can >work both ways then perhaps this is really a project management >issue, communication issue, or a programming guidelines issue, >rather than some real theoretical problem of using classes for >semantic purposes. A word of wisdom. Thanks. All I'm learning from this discussion is that it may be wise to use meaningful strings in the class attribute. For example, if you want to animate toolboxes, give them a class string like toolbox-animation, not just toolbox. I'm with the standard here. I think it makes sense to use the class attribute for any kind of grouping for which no other suitable attribute exists. In a way the class attribute is a joker---you can use it for anything. But if you do that, make sure that other people working with your code can easily understand what the class string means and does. But of course it is far from me to try to force other people here to do it that way too. If you are vehemently opposed to this kind of use, do something else. Could we perhaps briefly discuss what that something else may be? How am I supposed to define some HTML elements that are sprinkled across a page as belonging to a certain group? Hans-Georg
From: "Michael Haufe ("TNO")" on 3 Apr 2010 06:41 On Apr 3, 1:09 am, Garrett Smith <dhtmlkitc...(a)gmail.com> wrote: > Underlying problem? Earlier you wrote that the biggest issue was > predefined classes. Surely by now it should have been made clear from the posts thus far from myself and others. Repeating the same thing again and again is getting old, and I'm tired of doing it.
From: Antony Scriven on 3 Apr 2010 07:18 On Apr 3, 12:03 am, Michael Haufe wrote: > I'm saying that the spec should not have have allowed the > [class] attribute to mean *anything* the browser feels > like. I took it to mean anything the author feels like. I agree that having it mean anything the *browser* feels like is not a good thing. --Antony
From: Antony Scriven on 3 Apr 2010 07:22
On Apr 3, 12:17 am, Michael Haufe wrote: > On Apr 2, 3:55 pm, Antony Scriven <adscri...(a)gmail.com> > wrote: > > > In other words, use the class attribute purely for > > semantics. Sounds more reasonable to me. --Antony > > No one promoted this. I thought I was paraphrasing Scott in particular and one side of the argument in general. If not, then I just promoted it. --Antony |