This is the mail archive of the docbook-apps@lists.oasis-open.org mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Couple of minor issues with the XHTML DTD or XSL?


Daniel Veillard wrote:

> On Sat, Jan 12, 2002 at 09:25:16AM -0600, ttg@charter.net wrote:
> 
>>Hi,
>>It seems like the XHTML DTD or the XSL is generating a couple of
>>misformed tags.  Specifically the <p/> and <dl/> tags.
>>I am using xsmlproc with docbook-xsl-14.5 for my builds.
>>According to the W3C recommendations, (Appendix C),
>>
> 
>   The XHTML one:
> 
>   http://www.w3.org/TR/xhtml1/#guidelines
>     Appendix C. HTML Compatibility Guidelines
> 
> Please note:
> 
>    1/  "This appendix is informative."
>    2/  the word "Compatibility"
> 
> 
>>the minimized form of the <p></p> container should be
>><p /> with the leading space before the />.  
>>
> 
>   And a few of other "tweaks" which are not part of the
> requirement to serialize XML but mere attempts to get parsed
> with legacy code which usually doesn't handle XML (nor even
> HTML !) correctly in most cases. I honnestly tend to think
> that if you want to process HTML use an HTML aware processor
> if you want to process XML use an XML processor.
>   In a nutshell if you expect HTML clients, generate HTML trying
> to feed them XML in some convoluted ways ain't really a progress
> and should be limited to the extreme case where one really can't
> select HTML vs XML.
> 
> 
>>The DTD also generates a partial dictionary
>>list after the inserted TOC <dl/> and I can't
>>find that minimized form in the recommendations,
>>(that's not to say it isn't there <grin> but if it
>>is a valid minimized form, it too would appear
>>to need the leading space before the />.
>>
> 
>   The extra changes needed to output XHTML are not present in the
> XSLT specification. Either you output XML or you output HTML or you output
> text. The specific rules you are asking for don't follow any of these
> XSLT standard rules. So there is no way to generate them without
> requiring to some extensions in one way or another, you can't require
> that from XSLT directly.
>   I *could* tweak the libxml2 XML serializer to try to recognize XHTML
> specific XML documents and try to conform to those exotic rules. I'm
> usure it makes really any good in the long term.
> 
> Daniel



Hi Daniel,


I know this is avery old post but thought I should comment. I think that 
using validated XHTML is a very good approach and with the suggested w3 
"hacks" to help the older browsers parse/render I have had pretty good 
results in 4.0 and up browsers with XHTML strict. This allows the 
transitional xml recast of html to work today.

The br hr and probably the minimized p if that is allowed by the dtd 
really need to have the extra space to be rendered correctly. Isn't this 
  a XSL stylesheet issue anyway? Anyway hope I wasn't off base here.

Eric






Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]