From: Garrett Smith on
David Mark wrote:
> Garrett Smith wrote:
>> Michael Haufe ("TNO") wrote:
>>> 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.
>> You being tired is an excuse, not a reason.
>
> Do you ever stop to think that you are the problem. I have and I really
> think there's something to it.

The problem is trying to come to agreeement on what `class` must be used
for. That's not me.
--
Garrett
comp.lang.javascript FAQ: http://jibbering.com/faq/
From: David Mark on
Scott Sauyet wrote:
> Antony Scriven wrote:
>> 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
>
> Well, if I didn't say that, I should have.
>
> To the arguments that an attribute should be used for one thing only,
> I agree. But that one thing in the case of the class attribute has to
> do with logically grouping together otherwise unrelated elements.
> Ideally, this should be done with a term that's meaningful in your
> context: don't use "toolbox" if it's ambiguous in your environment.
>
> That is what the class attribute should be used for. If you then want
> to style the elements of that group in a particular way, you can add a
> CSS rule that references your class. If you want to hide those
> elements as they're not needed in your nifty Web2.0 Rich Internet
> Application, add some script that selects them using this class name.
> If you want to annoy the hell out of Thomas Lahn with your amateurish
> start-up animation on those elements, use them as hooks for this noble
> purpose.

It's not the animations that Thomas is specifically objecting to, but
the way they are typically accomplished (e.g. using a 60-70K black box
query engine that burdens the document with unneeded weight and
complexity, not to mention the potential for compatibility issues).

>
> I feel I haven't gotten satisfactory answers about the differences
> with the "id" attribute, but I want to ask another along the same
> lines.

What is wrong with the answer(s) you've received thus far?

> For those who are suggesting that the class attribute be used
> only for CSS, do you believe it's acceptable to use a single class
> attribute for screen, projection, and aural stylesheets, or should you
> have separate class attributes for each?

That's a silly question. For one, there can only be one class attribute
per element. For two, if you have any experience with such, you know
that common class names (or ID's) are key. I really can't imagine what
you are getting at with this question. Neither can I imagine using a
screen style sheet (which is constrained to just one type of screen).
Start with "all" then override as necessary for other media (including
other screen types).

> And if it's the latter,
> what's so different about also using them as hooks for scripting?
>

I assume you mean the former. (?) But either way, I don't see the
connection at all.
From: David Mark on
Garrett Smith wrote:
> David Mark wrote:
>> Garrett Smith wrote:
>>> Michael Haufe ("TNO") wrote:
>>>> 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.
>>> You being tired is an excuse, not a reason.
>>
>> Do you ever stop to think that you are the problem. I have and I really
>> think there's something to it.
>
> The problem is trying to come to agreeement on what `class` must be used
> for. That's not me.

Having read a large sample of your collective works here, I can state
without hesitation that you are a big problem. That last bit about
proving jQuery was "that awful" was really the last straw. Please stop
wasting everyone's time.
From: "Michael Haufe ("TNO")" on
On Apr 3, 2:57 pm, Garrett Smith <dhtmlkitc...(a)gmail.com> wrote:
> I did not promote HTML5 predefined classes. I used a microformat as an
> example of using class to annotate semantic meaning of element.

ok

> Thomas pointed out the problems with the design of that microformat and
> nobody disagreed. THose problems do not, however, refute the value or
> validity of the argument I proposed which was supported by microformats.

> | The class in the markup says something about the markup, not the CSS.
> | The HTML attribute in this case describes what sort of thing it is.
>
> That argument still stands and it is still valid.

But that is not how its being used as others on this thread have
mentioned.

> The class attribute represents a way to group elements into classes. The
> class is not just about CSS.

My argument has been about not utilizing the attribute for more than
one purpose all of which I have seen:

<div class="cssHook semanticHook group-data-foo">...</div>

Now if you had this it would be different as it would primarily be for
modeling the content with presentation layered on top:

<div class="semanticHookThatHadComplementingCSS">...</div>

Michael Haufe ("TNO") <t...(a)thenewobjective.com> wrote:
> I pointed out that the spec should have separated these two concerns.

On Apr 3, 2:57 pm, Garrett Smith <dhtmlkitc...(a)gmail.com> wrote:
> You did but you did not give any reason.

I did indeed. I said that not separating the concerns into different
attributes makes it difficult to discern the purpose of the value in
the first place, and David pointed out the issue with potential
collisions. If you look at the source code of Google Groups for
example, you can see another example of this problem:

<img [...] class="noscripthide scripthide script12hide script13inline
mrgl2">

Michael Haufe ("TNO") <t...(a)thenewobjective.com> wrote:
> David Mark promoted limiting yourself to using it for presentation only.

On Apr 3, 2:57 pm, Garrett Smith <dhtmlkitc...(a)gmail.com> wrote:
> Yeah, so what?

So his solution is to avoid the above mentioned problem by sticking to
one purpose.

Michael Haufe ("TNO") <t...(a)thenewobjective.com> wrote:
> Antony Scriven, I think without realizing it, showed how David's limitation can be
> unreliable as well:

On Apr 3, 2:57 pm, Garrett Smith <dhtmlkitc...(a)gmail.com> wrote:
> Antony reaffirmed the value of semantic meaning of classnames and
> pointed out the value in communication and process.

Which would point to my second example which both of them would agree
with I'm sure.

> The class attribute groups elements into a class of objects. I do not
> see the problem in understanding that.

The problem is that it's too ill-defined, not that it's hard to
understand.
From: David Mark on
On Mar 29, 3:11 am, Garrett Smith <dhtmlkitc...(a)gmail.com> wrote:
> David Mark wrote:
> > Garrett Smith wrote:
> >> David Mark wrote:
> >>> Garrett Smith wrote:
> >>>> Michael Haufe ("TNO") wrote:
> >>>>> On Mar 28, 4:44 pm, Eric Bednarz <bedn...(a)fahr-zur-hoelle.org> wrote:
> >>>>>> David Mark <dmark.cins...(a)gmail.com> writes:
> >>>>>>> Using class names for something other than intended indicates a bad
> >>>>>>> design.
> >>>>>> Class names have a general purpose role in HTML; I find it pretty hard
> >>>>>> to think of a use case that isn’t covered by that.
> >>>>> People are using class names for things they weren't meant to be used
> >>>>> for. Ironically people are trying to shoehorn semantic meaning into
> >>>>> HTML where it was already available in XHTML (go figure)
> >>>> The HTML class attribute is not meant to be limited for any particular
> >>>> task. What is`class` being used for that it was not meant for?
> >>> Asked and answered.  See my other post.
> >> Any answer coming from someone who exhibits such a strong aversion to
> >> reading specifications as you do is worthless.
>
> > You are clinging to that nonsense, aren't you?  As I have said, reading
> > specifications can only get you so far (and you are a prime example).  I
> > suppose in your simple-minded perception, that equates to a proposal to
> > not read specifications at all.  :)
>
> Never have I avocated not reading the specifications; quite the opposite.
>

See what I mean? :) You just can't read. Replying to you is
inviting an irritatingly wrong-minded response every time. How much
time and space has been wasted over the years trying to steer you back
on course?