[uf-dev] Case-sensitivity

Dan Connolly connolly at w3.org
Wed Jan 18 12:37:54 PST 2006


On Jan 18, 2006, at 2:02 PM, Tantek Çelik wrote:
> On 1/18/06 10:19 AM, "brian suda" <brian.suda at gmail.com> wrote:
>
>> I have noticed that a few people have been mis-using the TYPE 
>> attributes
>> for
>> a few properties, namely TEL and ADR.
>>
>> The problem is that instead of using ABBR they are just marking-up 
>> their
>> normal english prose. For example:
>>
>> <p class="tel">This is my <span class="type">Home</span> Phone number:
>> <span class="value">XXX-XXX-XXXX</span></p>
>>
>>
>> The problem is that class="type" of "Home" is NOT in the enumerated 
>> list
>> 'home' is, but 'Home' (capital H home is not).
>>
>> I know that the wiki says that the class values are case-specific, but
>> are the type-values case-specific as well? or should applications 
>> accept
>> home, Home, HOME, HoMe, etc as 'home'?
>
> Good point Brian.
>
> I thought I had specified this in hcard-parsing, but perhaps not.
>
> The class names are case-sensitive per HTML4.01 (see "A Touch of 
> Class" for
> more on that).
>
> The enumerated *values* are case-INsensitive, and thus yes, 
> applications
> should accept home, Home, HOME, HoMe, etc as 'home'.

Wow... that seems like 180 degrees from the answer I got earlier...

     *
          1.
                 o
                 +

     * 2005-07-23 raised by DanConnolly
          1. Are class names case sensitive or not? hcard says "If names 
in the source schema are case-insensitive, then use an all lowercase 
equivalent."
                 o A: ACCEPTED FAQ. Class names are case sensitive per 
the HTML4 specification. Hence hCard explicitly specifies the case of 
class name to use for source schema names that are case-insensitive.
          2. ...but I find example data with class="Given-Name"
                 o A: ACCEPTED RESOLVED. That is from an older 
preliminary version of the hCard spec which used mixed case class 
names. Such class names are no longer valid hCard. Please note which 
examples (URLs) are using the older class names and hopefully we can 
get them fixed.
                       + A: By Brian Suda (http://suda.co.uk) I have 
fixed all the references in the hcard-brainstorming page to reflect the 
lower-case style, this is a hold-over from the original design, X2V has 
been updated.
          3. ..and code that supports it [data with class="Given-Name"].
                 o A: ACCEPTED RESOLVED. Any code supporting the older 
class name(s) is for backward compatibility only, and should be phased 
out. Any new hCard code SHOULD NOT support such mixed case class names

  -- http://www.microformats.org/wiki/hcard-issues


-- 
Dan Connolly, W3C http://www.w3.org/People/Connolly/



More information about the microformats-dev mailing list