xsl-list
[Top] [All Lists]

Re: Image Tage Bug

2005-11-05 08:27:43
I think the question he is really asking is - is there an output method to specify the generation of xhtml so that <img /> and other empty tags like <br /> gets generated automatically (and conform to the W3C recommendation for compatibility with older browsers)?

I believe with xslt 2.0 you can specify an output method of xhtml - but with xslt 1.0 I am not sure if there is any commonly accepted way to do this (and also seems to be dependent on the specific application you are using as well). I generally wind up patching the output by hand - or running the file through some xhtml /validation-fix up routine... so would be interested in an answer to this as well.

Cheers...Hugh

CyberSpace Industries 2000 Inc.
XML Training and Consulting


----- Original Message ----- From: "andrew welch" <andrew(_dot_)j(_dot_)welch(_at_)gmail(_dot_)com>
To: <xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com>
Sent: Saturday, November 05, 2005 8:59 AM
Subject: Re: [xsl] Image Tage Bug


On 11/5/05, G Venkata Phanindra <phani_five(_at_)yahoo(_dot_)co(_dot_)in> wrote:
Hi..
I am a newbie to XSL and i am trying to convert an xml
file into an HTML ...
I need to add an Image in the HTML,i am defining HTML
image tag

     <img src=" " alt=" " />

No problem with HTML output. but when i submit this to
an XHTML validator its
giving OMIT TAG error as this is converted as

          <img src= " " alt=" ">

 the / is missing how can i handle this.

Code

<?xml version='1.0' encoding='utf-8' ?>
<xsl:stylesheet
xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
version="1.0">
<xsl:output method="html" version="1.0"


You've specified output method 'html', so you probably want to submit
it to a HTML validator instead of an XHTML validator.

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--





--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--



<Prev in Thread] Current Thread [Next in Thread>