Welcome to WebHeadStart.org

Web Technologies

Sponsored By

WebHeadStart.org is currently in beta.
Please pardon our appearance as we work to provide you with the most comprehensive reference on today's web technologies.

Interested in advertising on WebHeadStart? Become an advertising partner today!

[WWW-HTML Mailing List Archive Home] [Messages By Thread] [Messages By Date]

Re: WD-xhtml2-20030506: <qst>ions and <ans>wers

From: Dave Hodder <dmh@dmh.org.uk>
Date: Fri, 25 Jul 2003 22:28:18 +0100
Message-ID: <3F21A0F2.3000109@dmh.org.uk>
To: www-html@w3.org

Chris Moschini wrote:

<snip/>

> <qa>
>   <qst>.....?</qst>
>   <ans>
>   <qa>
>     <qst>Did...that?</qst>
>     <ans>....</ans>
>   </qa>
>   </ans>
> </qa>
> 
> I actually think this is an excellent model and would be a useful addition to the spec. Note that using the qa wrapper means you can have multiple questions with 1 answer if you like, or multiple answers to one question - both are valid cases and here, semantically valid. You could unfortunately end up with multiple of both, which a confused HTML'er may do - is it possible to specify in the DTD that it's 1+ of one but 1 of the other OR 1 of one and 1+ of the other?

Thinking about it, I'd personally prefer having a <qa> element 
containing one <qst> followed by zero or more <ans>, i.e. <!ELEMENT qa 
(qst,ans*)>.  Otherwise it strikes me as unnecessarily complicated.  As 
Lanny Heidbreder has pointed out, this would make it quite similiar to a 
definition list, except that <dt> is restricted to Inline content (<qst> 
and <ans> should really allow Flow, like <dd>).

> This would provide a lot of interesting opportunities for UAs, including easily "Googling" the answers to questions, and validating a document to find there's a question you haven't answered ("Error: qa element without at least 1 ans element").

I agree <qst>/<ans> could potentially be useful to software agents; e.g. 
for a more question-orientated search engine.  But I think a <qa> 
element should contain zero or more <ans> rather than one or more -- on 
the basis that there're some questions that really shouldn't be 
answered.  ;o)

Cheers,

Dave
Received on Friday, 25 July 2003 17:28:17 GMT
Valid XHTML 1.0! Valid CSS! Site Map | Privacy Policy | Terms of Use | WebHeadStart.org © 2005 All Rights Reserved.