logo       

Re: patch for showing alerts when an item is invalid and nested in a repeat: msg#00002

text.xml.xforms.chiba.devel

Subject: Re: patch for showing alerts when an item is invalid and nested in a repeat

hi zach,

as we overhauling the stylsheets in the course of implementing full-blown ajax support, we will revisit this issue. the mip rendering for repeats will be fixed.

regards,
uli.

Zach Roberts wrote:
Hello All,

A while back (http://sourceforge.net/mailarchive/message.php?msg_id=10744999) there was a discussion about a bug in the servlet view of Chiba (chiba-web), specifically using the ie-xforms.css and a xforms:repeat block. The problem was that any control inside the xforms:repeat that was found to be invalid was not displaying the alert as expected because of CSS inheritance from the HTML table element that was generated as the xforms:repeat container. We talked a bit about the problem, but nobody came up with a proper solution. So, I cobbled together the attached one line patch which is working for our installation quite nicely. I have also attached a test form from the previous discussion. Please test it out, and merge it back into the code base if you wish. Thanks again,

Zach Roberts


------------------------------------------------------------------------

Index: html4.xsl
===================================================================
RCS file: /cvsroot/chiba/chiba-web/web/forms/xslt/html4.xsl,v
retrieving revision 1.7
diff -u -r1.7 html4.xsl
--- html4.xsl 30 Sep 2005 10:48:49 -0000 1.7
+++ html4.xsl 17 Oct 2005 21:30:51 -0000
@@ -544,6 +544,7 @@
<xsl:variable name="valid">
<xsl:choose>
<xsl:when test="string-length(chiba:data) = 0 and
chiba:data/@chiba:visited='false'">valid</xsl:when>
+ <xsl:when test="@chiba:index and
//chiba:data/@chiba:valid='false'">invalid</xsl:when>
<xsl:when
test="chiba:data/@chiba:valid='true'">valid</xsl:when>
<xsl:otherwise>invalid</xsl:otherwise>
</xsl:choose>


--
Ulrich Nicolas Lissé



-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise