Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: Empty element match

From: Tjerk Wolterink <tjerk@------------------.--->
To: NULL
Date: 7/1/2005 3:13:00 PM
David Carlisle wrote:
>   Errors like this:
>   line 11 column 5 - Warning: <meta> element not empty or not closed
> 
> Looks like those come from an XMl parser.
> Parsing HTML with an XML parser is like parsing FORTRAN with a CParser,
> you get errors, but it doesn't mean that there is anything wrong with
> the file.
> 
>   A piece of the generated html page:
> 
> That looks Ok except of course all teh xml namespace declarations 
> xmlns:... are invald html attributes.
> 
> 
> 
>>With closing i also mean: <br/> (properly closed empty tag)
> 
> 
> But as I said /> is XML syntax. It is not the syntax for an empty element
> in HTML.
> 
> 
>>Ok i understand, but html transitional and html strict are not xml
>>languages? Or am i interchanging xhtml and html wrongly?
> 
> 
> No version of HTML is an XML language. They are all defined via SGML
> DTD. The XML versions are all called XHTML.
> 
> 
>>So the conclusion of this is:
>>IF your writing an html application that uses xsl transformation
>>to output the html, then
>>you have to change the xsl for each xsltransformer-implementation,
> 
> 
> No that is not the conclusion at all.
> You don't have to change your stylesheet but you may have to specify
> that you want html serialisation in other (system specific) places.
> The reason why XSLT doesn't mandate that xsl:ouput always has an effect
> is that it allowes the result tree to be passed on as an in-memory treee
> (or stream of sax events, or any other internal representation) This is
> what happens in cocoon or if you run xslt inside of mozilla.
> If the result tree is being passed on in such an in-memory format it is
> never serialised to a linear document including tags so the hints on
> xsl:output as to how to serialse the tree are never used.
> 
> 
> 
>>Is there no possibility to enforce the parser to use <br/> for
>>empty tags?
> 
> 
> You can force xslt to use <br/> syntax by using the xml output method,
> but that is not correct html markup for a line break..
> 
> You have to decide what you want to do, generate html or generate xhtml,
> and in the later case you need to decide if you want to make IE be able
> to read the file as it has no built in xhtml support (unlike say mozilla
> or opera which can render xhtml files).
> 
> The simplest, if you do not need xhtml in the document, is just to
> generate html.
> 
> David

ok i want html,

but why how do i overcome the problem that the parser/transformer
on the hostingprovider does not listen to the xsl:output method attribute?

Now it just renders to the xml output method, and that does not render 
well in internet explorer.


transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent