[uf-discuss] parameterized classes?

Charles Iliya Krempeaux supercanadian at gmail.com
Sat Oct 28 19:32:43 PDT 2006


Hello,

This is somewhat off-topic.

I was wondering what people thought about parameterized classes?

For example...

<a class="group:x" href="a.html"></a>
<a class="group:x" href="a.rss"></a>
<a class="group:x" href="a.atom"></a>

<a class="group:y" href="b.png"></a>
<a class="group:y" href="b.jpg"></a>



Perhaps the above could be Semantic HTML to mark alternate links.

Where "a.html", "a.rss", and "a.atom" would be a set of alternates.
And "b.png" and "b.jpg" would be another set of alternates.

(This would have the advantage where these links could be very very
loosely coupled.  Which is why I might write Semantic HTML like this.)

I believe that CSS would have problems styling these types of class
names.  For example, you could NOT do something like:

.group\:* {
    /* CSS stuff here */
}

Those types of CSS wildcards aren't allowed AFAIK.

But JavaScript could handle these types of class names relatively easy.

Can anyone see any draw back from using parameterized classes?


See ya

-- 
    Charles Iliya Krempeaux, B.Sc.

    charles @ reptile.ca
    supercanadian @ gmail.com

    developer weblog: http://ChangeLog.ca/


More information about the microformats-discuss mailing list