[
Lists Home |
Date Index |
Thread Index
]
there's a lot of personal preference here.
i use attributes when they characterise the tag, end elements when they
are contents of the tag.
e.g.
<table name="x">
<record>...</record>
</table>
it's a long perma thread, and this probably only reflects the way my
mind works.
rick
On Fri, 2004-04-23 at 11:22, Jonathan Borden wrote:
> On Apr 21, 2004, at 8:51 AM, <kynn@panix.com> wrote:
> >
> >
> > But I am interested in learning to recognize those rare situations
> > in which, as a designer, one *should* put a particular attribute
> > in a namespace. This is still very unclear to me. What are the
> > requirements that an attribute must fulfill to be a good candidate
> > for being placed in a namespace by the schema/DTD designer?
> >
> Generally if the use of the attribute is always taken in context of its
> parent element then the attribute need not be namespace qualified. On
> the other hand, if attributes are intended to have meaning regardless
> of which element it is attached to, the attribute ought be namespace
> qualified.
>
> For example, XLink attributes can be defined on potentially any element
> -- these are namespace qualified, and define a link regardless of the
> name of the element.
>
> Another example is RELAXNG
>
> <rng:element name="foo" > ...
>
> In this case there is no need to namespace qualify the "name" attribute
> as its meaning is determined by the rng:element.
>
> That's how I see it.
>
> Jonathan
>
>
> -----------------------------------------------------------------
> The xml-dev list is sponsored by XML.org <http://www.xml.org>, an
> initiative of OASIS <http://www.oasis-open.org>
>
> The list archives are at http://lists.xml.org/archives/xml-dev/
>
> To subscribe or unsubscribe from this list use the subscription
> manager: <http://www.oasis-open.org/mlmanage/index.php>
>
|