I have also discovered a big bug then :

suppose you want to use this :

<html>

..
<select>
<xsp:logic>
        String selected = (true) ? "yes" : "";
</xsp:logic>
        <option value="x">
                <xsp:attribute
name="selected"><xsp:expr>selected</xsp:expr></xsp:attribute>
                ValueX
        </option>
</select>

..
</html>


Well... <option selected=""> is unfortunately equivalent in html to
<option selected="yes"> and <option selected>

...


I have then to write this piece of code like this :


<select>
<xsp:logic>
        String selected = (true) ? "yes" : "";
        
if (selected.equals("")) {
        <xsp:content><option value="x"
selected="yes">hhhhhh</option></xsp:content>
} else {
        <xsp:content><option value="x">hhhhhh</option></xsp:content>
}
</xsp:logic>
</select>


it is not very elegant...

---------------------------------------------------------------------
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: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>

Reply via email to