You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Thangadurai <du...@siptech.co.in> on 2001/09/04 08:50:07 UTC

Hi All,
  I am new to cocoon.... i have  problem while using  html <option>tag
in my xsl.
 Please see the following xsp and xsl files

*********My xsp page ****************

<?xml version="1.0"?>
<?xml-stylesheet href="option.xsl" type="text/xsl"?>
<?cocoon-process type="xslt"?>

<xsp:page language="java"
   xmlns:xsp="http://www.apache.org/1999/XSP/Core">

 <page>

 </page>

</xsp:page>

************My xsl(option.xsl)*****************

<?xml version="1.0"?>

<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

  <xsl:template match="page">

   <select name="audience" size="1">
           <option value="PL1">PL</option>
           <option selected="true" value="ALL">ALL</option>
          </select>
 </xsl:template>

</xsl:stylesheet>

************I got the following result (Note that the option tags are
not closed)**********

<select name="audience" size="1"><option value="PL1">PL<option selected
value="ALL">ALL</select>

*************************

I couldn't find the reason for, why the option tags are not closed...
Do you know..?




---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>


Re:

Posted by Jörg Heinicke <jh...@virbus.de>.
You are using the HTML-serializer, so you get HTML-output. And in HTML the 
<option>-tags shouldn't be closed (backward compatibility).

Joerg

Thangadurai wrote:
> Hi All,
>   I am new to cocoon.... i have  problem while using  html <option>tag
> in my xsl.
>  Please see the following xsp and xsl files
> 
> *********My xsp page ****************
> 
> <?xml version="1.0"?>
> <?xml-stylesheet href="option.xsl" type="text/xsl"?>
> <?cocoon-process type="xslt"?>
> 
> <xsp:page language="java"
>    xmlns:xsp="http://www.apache.org/1999/XSP/Core">
> 
>  <page>
> 
>  </page>
> 
> </xsp:page>
> 
> ************My xsl(option.xsl)*****************
> 
> <?xml version="1.0"?>
> 
> <xsl:stylesheet version="1.0"
> xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
> 
>   <xsl:template match="page">
> 
>    <select name="audience" size="1">
>            <option value="PL1">PL</option>
>            <option selected="true" value="ALL">ALL</option>
>           </select>
>  </xsl:template>
> 
> </xsl:stylesheet>
> 
> ************I got the following result (Note that the option tags are
> not closed)**********
> 
> <select name="audience" size="1"><option value="PL1">PL<option selected
> value="ALL">ALL</select>
> 
> *************************
> 
> I couldn't find the reason for, why the option tags are not closed...
> Do you know..?


---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>