|
From: Dan M. <d-...@uc...> - 2001-05-29 05:23:36
|
On Mon, 28 May 2001, Mary Dwyer wrote:
> < Dan Meuth wrote>
>
> > Right. I hadn't thought of this until you pointed it out. This does not
> > describe what the index really looks like - it has one Panel item with
> > three links, not three items named "Panel" each with one link. For this
> > reason, the id's should be children instead of attributes.
> >
> > > - the following solution appealed, but unfortunately ID and IDREFs as
> element
> > > content is illegal :-)
> >
> > Why is it illegal?
>
> Norm Walsh pointed out, from the following example, that
> | <primary>
> | <title>Main Menu</title>
> | <secondary>
> | <title>Example</title>
> | <linkid>idx-a3</linkid>
> | <id>id10533</id>
>
> ".... putting ID or IDREF values in element content is discouraged
> by the W3C XML Schemas Recommendation and simply won't work for DTDs."
>
> Given what Laszlo pointed out earlier about my incorrect use of <id>, I'm not
> sure whether the above applies just to a misuse of the <id> tag in my example or
> whether it also applies to an entry such as <linkid>idx-a3</linkid> ?
I'm not certain what the rational behind this recommendation is, or
whether it would apply to our situation. At any rate, I think we can
easily follow the recommendation and make this into an attribute:
<indexdoc>
<primary title="Apple">
<secondary title="Big">
<tertiary title="Green">
<link linkid="idx-a1"/>
<link linkid="idx-a2"/>
</tertiary>
...
instead of the previously suggested:
<indexdoc>
<primary title="Apple">
<secondary title="Big">
<tertiary title="Green">
<linkid>idx-a1</linkid>
<linkid>idx-a2</linkid>
</tertiary>
Dan
|