W3C home > Mailing lists > Public > public-xhtml2@w3.org > December 2007

Attributes and namespaces?

From: Kenny Johar <kenny.johar@visionaustralia.org>
Date: Tue, 11 Dec 2007 20:58:35 +1100
Message-ID: <A921AF4A5FC01245A8D846D004B61B3604F7CAA4@kooxch01.visionaustralia.org>
To: <public-xhtml2@w3.org>
Cc: <unagi69@concentric.net>
Dear List,
After an exhausting last few weeks with xml attributes, and how
namespaces work with them, Gregory kindly pointed me to this list.
Can you please help me understand the following:
By default xml attributes do not inherit default namespaces, for
example, in the following piece of xml:
 <person xmlns=http://tempuri.org <http://tempuri.org> " age="80"
name="someName" />
my understanding is, that the age and name attributes should not belong
to the namespace http://tempuri.org. 
Also, in the following piece of xml:(please note, the prefix xs belongs
to the w3c schema namespace)
<xs:element name="fullname" type="xs:string">
the name and type attributes should not inherit the namespace bound to
the "xs" prefix. herein lies the source of my agony. If this is the
case, then how could the above be legal w3c markup, where the name and
type attributes belonged to the namespace bound to the "xs" prefix? 
If the assertion that by default, xml attributes do not inherit either
default namespaces or a namespace bound to the parent element is true,
then would the xhtml2 language for example, not require every single
attribute of every single element to be qualified with a prefix, in
order to be treated as a part of the xhtml2 vocabulary? To illustrate
this point better, would the following markup not be required if the
assertion above was true:
<html xmlns:xhtml2=".......">
<p xhtml2:style=... xhtml2:class=....>
Qualifying each attribute with a prefix to ensure its membership of a
parent language, does not seem to be the requirement for either xhtml2
or a raft of other xml-based languages. How then are attributes
automatically given the membership of a default namespace or the
namespace of the parent element?
As I am not currently a member of this list, can you please send me your
comments on:
I will be eternally thankful to you. This issue has boggled my mind for
way too long now and I would like to get some clarity on it once and for
thanks a ton in advance.
Warm Regards,
Kenny Johar
Research, Architecture and Solutions Lead
Vision Australia
454 Glenferrie Road, Kooyong, VIC 3144
P: 03 9864 9277
F: 03 9864 9387
ABN: 67 108 391 831
ACN: 108 391 831 
Vision Australia is a living partnership between people who are blind,
sighted or have low vision. We are united by our passion that in the
future people
who are blind or have low vision will have access to and fully
participate in every part of life they choose. 
This email (including its attachments) is confidential and may contain
legally privileged material or personal information. If you are not a
named addressee
you must not use, disclose, copy, disseminate or print the email or any
information in it. If you have received this email in error please
notify us immediately
and delete the email and any copies. 
Vision Australia is not responsible for any changes made to a document
other than those made by Vision Australia or for the effect of the
changes to the
document's meaning. Vision Australia accepts no liability for any damage
caused by this email or its attachments due to viruses, interference,
corruption or unauthorised access. 
Received on Wednesday, 12 December 2007 20:05:19 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 20:30:29 UTC