- From: John Boyer <boyerj@ca.ibm.com>
- Date: Wed, 26 May 2010 15:16:33 -0700
- To: "Klotz, Leigh" <Leigh.Klotz@xerox.com>
- Cc: "Jabba Laci" <jabba.laci@gmail.com>, "xforms" <www-forms@w3.org>
- Message-ID: <OFC3AA2B1E.A304AED4-ON8825772F.0079CB31-8825772F.007A6035@ca.ibm.com>
Minor point.
All the essential points Leigh makes are correct, but you can in fact put
an xforms:output inside of an xforms:hint.
See the second table here:
http://www.w3.org/TR/2009/REC-xforms-20091020/#controls
The content model for xforms:hint includes UIContent, which is defined to
contain outputs:
http://www.w3.org/TR/2009/REC-xforms-20091020/#elems-inline
The essential issue, though, is that an xforms output cannot appear
directly inside other controls, but rather have to appear in these
metadata elements. Moreover, the content model of output is a label, so
you could put your text in that (along with more outputs, in fact).
However, the purpose of output is not really to hold just plain text, but
usually it is to use a binding or value attribute to output data to the
presentation layer, since as Leigh points out you can just put plain text
directly into elements like xforms hint.
Cheers,
John M. Boyer, Ph.D.
STSM, Lotus Forms
Workplace, Portal and Collaboration Software
IBM Victoria Software Lab
E-Mail: boyerj@ca.ibm.com
Blog: http://www.ibm.com/developerworks/blogs/page/JohnBoyer
Blog RSS feed:
http://www.ibm.com/developerworks/blogs/rss/JohnBoyer?flavor=rssdw
From:
"Klotz, Leigh" <Leigh.Klotz@xerox.com>
To:
"Jabba Laci" <jabba.laci@gmail.com>, "xforms" <www-forms@w3.org>
Date:
05/26/2010 01:26 PM
Subject:
RE: problem with multiple pages (switch/case)
Laszlo,
I tested your multipage-problem.xhtml under AgenceXML XSLTForms and was
able to see the buttons (and cases) for page 1,3,4,5,6.
I understand you removed page 2.
I made a few changes:
1. Remove the DTD header
The file is not XHTML, but XHTML+XForms, so DTD validation is incorrect.
Since the XHTML DTD defines the entity, I replaced those with
 
The & entity is predefined in XML so it's OK.
2. Fix validation errors in XForms
Instead of
<xforms:output>(minimal value: 1.0 ; maximal value:
500.0)</xforms:output>
Use
<xforms:hint>(minimal value: 1.0 ; maximal value:
500.0)</xforms:hint>
xf:output doesn't use text inside it, and xf:output cannot appear inside
other controls.
Move the xf:output elements outside of xf:upload, as xf:output cannot
appear inside other form controls.
3. Change to use XSLTForms
In place of the DTD header, use this instead:
<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet href="/xsltforms/xsltforms.xsl" type="text/xsl" ?>
<?xsltforms-options css="no" debug="yes" ?>
Of course, to do this you must have a recent SVN version of XSLTForms
available at the stylesheet href.
If you still have this same problem under XSLTForms, please write back.
However, if this fixes your problem, I think it means you have found a bug
in Mozilla XForms and you can discuss it on the dev-tech-xforms mailing
list that mozilla.org hosts. (Of course, if you find bugs specific to
XSLTForms that aren't general XForms problems, the xsltforms-support
mailing list is the appropriate place to report them.)
Leigh.
-----Original Message-----
From: www-forms-request@w3.org [mailto:www-forms-request@w3.org] On Behalf
Of Jabba Laci
Sent: Tuesday, May 25, 2010 4:43 PM
To: xforms
Subject: Re: problem with multiple pages (switch/case)
> Second, you might try de-coupling your JSP and XForms problems and
testing them separately. The JSP processing all happens before the
XHTML+XForms page is delivered to Firefox, so either the page it produces
isn't correct, or there's a bug in the Mozilla XForms feature. Is it
possible for you to "Save" the page from Firefox locally and run it
locally? You may need to convert instance initiailizations to relative
references to files instead of having it go back to the server.
Hi,
Thanks for the two answers. We have tried several variations, without
success. I would like to send you a problematic file, maybe someone could
help me:
http://dl.dropbox.com/u/144888/share/multipage-problem.xhtml
( the same file in .zip:
http://dl.dropbox.com/u/144888/share/multipage-problem.xhtml.zip )
[If you click on the link, most probably it will work fine, but if you
save it and open it locally with the file:// protocol, the last two tabs
are not shown.]
I took the JSP file and removed all JSP calls, so now it's just a plain
XHTML file. In our application these JSP files are generated, we have lots
of them. The problem is that sometimes the last (or the last
two) pages are not shown correctly, i.e. the part in the "case" block is
hidden.
We have two cases:
(1) The JSP page is not shown correctly, BUT after a page refresh in the
browser everything is OK.
(2) The JSP page is not shown correctly, and page refreshes in the browser
do not help.
As I noticed, small JSP files tend to fall in category (1), while large
XForms (size of the source > 100 KB) fall in (2).
I took a sample from category (2), converted it to local XHTML file (no
JSP calls), and when opened through the file:// protocol, the last two
pages are not shown. To reduce the size, "page 2" is removed. The file is
quite big, but if I remove one more tab, it seems to work.
However, we would need all tabs, and some forms are even larger.
Thanks,
Laszlo
Received on Wednesday, 26 May 2010 22:17:08 UTC