Re: [Xsltforms-support] XForms repeat and tables?
Brought to you by:
alain-couthures
|
From: Alain C. <ala...@ag...> - 2021-03-30 17:29:49
|
<!doctype html>
<html>
<head>
<meta charset="UTF-8">
</head>
<body>
<div>
Tim,
</div>
<div class="default-style">
<br>
</div>
<div class="default-style">
Since XSLTForms 1.5, repeats within tables are converted into attributes ("xf-repeat-ref" or "xf-repeat-bind") without adding potentially missing tbody elements.
</div>
<div class="default-style">
<br>
</div>
<div class="default-style">
XSLTForms 1.5.4 now supports table/xf:repeat, not just tbody/xf:repeat.
</div>
<div class="default-style">
<br>
</div>
<div class="default-style">
Nevertheless, browsers add tbody element when not present. It does not seem to disturb XSLTForms in small test cases... Explicit tbody element sounds more secure...
</div>
<div class="default-style">
<br>
</div>
<div class="default-style">
Thank you for your feedback!
</div>
<div class="default-style">
<br>
</div>
<div class="default-style">
--Alain
</div>
<blockquote type="cite">
<div>
Le 29/03/2021 19:36, Tim Thompson <tim...@gm...> a écrit :
</div>
<div>
<br>
</div>
<div>
<br>
</div>
<div dir="ltr">
<div>
Thank you, Alain!
<br>
</div>
<div>
<br>
</div>
<div>
Is it possible to generate a table without a "tbody" element? With 1.5.3, removing "tbody" in my sample form still throws a "TypeError: Cannot read property 'localName' of null" in Chrome, but works in Firefox.
<br>
</div>
<div>
<br>
</div>
<div>
Best regards,
</div>
<div>
Tim
</div>
<div>
<br>
</div>
<div>
<br>
</div>
<div>
<div data-smartmail="gmail_signature" class="gmail_signature" dir="ltr">
<div dir="ltr">
--
<br>Tim A. Thompson
<br>Metadata Librarian
<br>Yale University Library
<br>
<br>
</div>
</div>
</div>
<br>
</div>
<br>
<div class="gmail_quote">
<div class="gmail_attr" dir="ltr">
On Mon, Mar 29, 2021 at 1:25 PM Alain Couthures <<a href="mailto:ala...@ag...">ala...@ag...</a>> wrote:
<br>
</div>
<blockquote>
<u></u>
<div>
<div>
Hello Tim,
</div>
<div>
<br>
</div>
<div>
There was a missing initialization in XSLTForms 1.5.2 for table repeats within a repeat.
</div>
<div>
<br>
</div>
<div>
This has been added as XSLTForms 1.5.3 at <a target="_blank" href="https://github.com/AlainCouthures/declarative4all/raw/master/public/direct/xsltforms.zip" rel="noopener">https://github.com/AlainCouthures/declarative4all/raw/master/public/direct/xsltforms.zip</a>
<br>
</div>
<div>
<br>
</div>
<div>
Because of XPath 3 support to be committed in next major release, XSLTForms 1.5.3 can use both current and future XPath engines. It is just an intermediate release. Please check all your forms!
</div>
<div>
<br>
</div>
<div>
Kind regards,
</div>
<div>
<br>
</div>
<div>
--Alain
</div>
<blockquote type="cite">
<div>
Le 28/03/2021 23:03, Tim Thompson <<a target="_blank" href="mailto:tim...@gm..." rel="noopener">tim...@gm...</a>> a écrit :
</div>
<div>
<br>
</div>
<div>
<br>
</div>
<div dir="ltr">
<div>
Thanks again, Josselin, Habs. Yes, I was using the latest version of XSLTForms, 1.5.2. If I remove the "tbody" element, the form works in Firefox, but throws an error in Chrome. However, if I revert to version 1.4, then it works both with and without "tbody," in both Firefox and Chrome. The issue seems to arise starting with version 1.5beta (655).
<br>
</div>
<div>
<br>
</div>
<div>
Best regards,
</div>
<div>
Tim
</div>
<div>
<br>
</div>
<div>
<br>
</div>
<div>
<div dir="ltr">
<div dir="ltr">
--
<br>Tim A. Thompson
<br>Metadata Librarian
<br>Yale University Library
<br>
</div>
</div>
</div>
</div>
<br>
<div class="gmail_quote">
<div dir="ltr" class="gmail_attr">
On Sun, Mar 28, 2021 at 3:44 PM Habs <<a target="_blank" href="mailto:ge...@us..." rel="noopener">ge...@us...</a>> wrote:
<br>
</div>
<blockquote>
On Sun, 28 Mar 2021, Tim Thompson wrote:
<br>
<br>> Thanks, Habs! Where you say the "tbody" tags are removed, do you mean in the XForm itself, or from the rendered HTML? If I remove them from the XForm, I
<br>> still get an error.
<br>>
<br>> However, if I copy the rendered content of the form, save it, and open it in the browser, then the table displays correctly. (See attached.) So, there must
<br>> be something in the XSLTForms JavaScript that is hiding the content?
<br>>
<br>
<br>Hi Tim
<br>
<br>Yes I removed the tbody from the Xform and it worked on my setup with
<br>latest xsltforms series (not sure what revision though sorry).
<br>
<br>I took your stripped (of anything but essential?!) Xform and plugged it
<br>into my goto basic xhtml document format (headers etc) on my test server.
<br>
<br>I simplify xforms to the absolute basics in problem cases I've had - see
<br>if that works and then build back up from there.
<br>
<br>I'll have another play and see if I can spot anything else.
<br>
<br>If you want my test version of your form let me know.
<br>
<br>Regards
<br>
<br>--- Sent using Alpine/Pine, probably the best MUA ---
<br>
</blockquote>
</div>_______________________________________________ Xsltforms-support mailing list <a target="_blank" href="mailto:Xsl...@li..." rel="noopener">Xsl...@li...</a> <a target="_blank" href="https://lists.sourceforge.net/lists/listinfo/xsltforms-support" rel="noopener">https://lists.sourceforge.net/lists/listinfo/xsltforms-support</a>
</blockquote>
</div>
</blockquote>
</div>
</blockquote>
</body>
</html>
|