xsltforms-support Mailing List for XSLTForms (Page 30)
Brought to you by:
alain-couthures
You can subscribe to this list here.
2009 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
(6) |
Jun
(9) |
Jul
(16) |
Aug
(5) |
Sep
(43) |
Oct
(36) |
Nov
(58) |
Dec
(43) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2010 |
Jan
(79) |
Feb
(81) |
Mar
(107) |
Apr
(93) |
May
(85) |
Jun
(54) |
Jul
(64) |
Aug
(54) |
Sep
(45) |
Oct
(53) |
Nov
(34) |
Dec
(77) |
2011 |
Jan
(56) |
Feb
(53) |
Mar
(52) |
Apr
(66) |
May
(44) |
Jun
(16) |
Jul
(28) |
Aug
(5) |
Sep
(15) |
Oct
(21) |
Nov
(51) |
Dec
(46) |
2012 |
Jan
(16) |
Feb
(38) |
Mar
(47) |
Apr
(45) |
May
(41) |
Jun
(41) |
Jul
(72) |
Aug
(17) |
Sep
(10) |
Oct
(16) |
Nov
(29) |
Dec
(30) |
2013 |
Jan
(25) |
Feb
(13) |
Mar
(20) |
Apr
(25) |
May
(34) |
Jun
(8) |
Jul
(12) |
Aug
(9) |
Sep
(21) |
Oct
(19) |
Nov
(6) |
Dec
(2) |
2014 |
Jan
(14) |
Feb
(8) |
Mar
(7) |
Apr
(13) |
May
(33) |
Jun
(13) |
Jul
(6) |
Aug
(5) |
Sep
(5) |
Oct
(34) |
Nov
(7) |
Dec
|
2015 |
Jan
(1) |
Feb
(6) |
Mar
(17) |
Apr
(12) |
May
(10) |
Jun
(18) |
Jul
(31) |
Aug
(9) |
Sep
(3) |
Oct
(6) |
Nov
(19) |
Dec
(1) |
2016 |
Jan
(18) |
Feb
(4) |
Mar
(13) |
Apr
(19) |
May
|
Jun
(17) |
Jul
(7) |
Aug
|
Sep
(3) |
Oct
(6) |
Nov
(3) |
Dec
|
2017 |
Jan
(5) |
Feb
(17) |
Mar
(4) |
Apr
(8) |
May
(3) |
Jun
|
Jul
(8) |
Aug
(2) |
Sep
|
Oct
(5) |
Nov
(6) |
Dec
(4) |
2018 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(6) |
Nov
|
Dec
(1) |
2019 |
Jan
|
Feb
|
Mar
(4) |
Apr
(2) |
May
(4) |
Jun
|
Jul
|
Aug
(2) |
Sep
(7) |
Oct
|
Nov
|
Dec
|
2020 |
Jan
(13) |
Feb
(17) |
Mar
(8) |
Apr
(11) |
May
(15) |
Jun
(11) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(6) |
2021 |
Jan
(9) |
Feb
(26) |
Mar
(17) |
Apr
|
May
(7) |
Jun
(18) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(10) |
2022 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
(3) |
Jun
|
Jul
|
Aug
(2) |
Sep
(3) |
Oct
(2) |
Nov
(10) |
Dec
(1) |
2023 |
Jan
(10) |
Feb
|
Mar
(7) |
Apr
(8) |
May
(3) |
Jun
|
Jul
|
Aug
|
Sep
(8) |
Oct
(11) |
Nov
(8) |
Dec
(5) |
2024 |
Jan
(7) |
Feb
(3) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2025 |
Jan
(4) |
Feb
(2) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: William V. <wve...@vi...> - 2013-10-21 17:24:25
|
Hi everybody, I'm building an XForms where the user could be able to paste XML code in a textarea and then apply an XSL transformation to the pasted code. In order to be able to do it, I tried two alternatives with no success: 1. Parse the XML code and store it in an instance (there is no function to parse xml text to instances) 2. Directly apply the transformation to the XML code and store the result in an instance (the transform() function only accepts nodes as input, not plain text. The missing piece is how to parse the content of the textarea. XPath 3.0 defines serialize()to convert an instance to text and parse-xml() to do the reverse process. XSLTForms implements the serialize() function, but the parse-xml() is not available. Some body knows a shortcut to do this? Thanks in advance, William David Velásquez Director de Investigación y Desarrollo Visión Tecnológica S.A.S. www.visiontecnologica.com<http://www.visiontecnologica.com> Follow me @williamda |
From: William V. <wve...@vi...> - 2013-10-18 20:48:03
|
Hi Lists, This was reported previously by Ingrid Falk in the XSLTForms-support list, with no satisfactory solution then: http://sourceforge.net/p/xsltforms/mailman/message/30743626/ When you create a XForms as an XML document (not an XQuery) stored in an eXist-db collection, you cannot simply access it by its URL. You get this message when executing the XSLT transformation on the server: --------------- HTTP ERROR 400 Problem accessing /exist/rest/db/sandbox/repeat.xml. Reason: Error while serializing XML: java.io.FileNotFoundException: C:\bin\eXist-db\config.xsl (El sistema no puede encontrar el archivo especificado) Powered by Jetty:// ---------------- Aprox. translation for "El sistema no puede encontrar el archivo especificado" is "System can't find the specified file" in Windows, or "Not such file or directory" in Linux I must admit that I solved it copying CONFIG.XSL from the XSTForms directory to the $EXIST_HOME path on the server. Today I discovered than changing from Saxon to Xalan as XSLT engine, the transformation works fine again. By default, eXist-db 2.0 comes with the following configuration in conf.xml: <transformer class="net.sf.saxon.TransformerFactoryImpl"> If you change to: <transformer class=" org.apache.xalan.processor.TransformerFactoryImpl"> XForms with XSLTForms server side work fine again. The problem also affects XForms with external css stylesheets using <link rel= .... element. Saxon fails to do the transformation with the same error above. I think the problem is to due to Saxon being unable to resolve relative URLs in XSLT stylesheets to the proper document inside eXist-db collections. For people trying to use XSLTForms into eXist-db is a good idea to switch to Xalan instead of Saxon, until somebody suggest a solution. Regards, - BIll |
From: William V. <wve...@vi...> - 2013-10-08 13:37:01
|
In the recent releases you can also use javascript functions directly in your XPath expressions. Take a look to the example on this message: http://sourceforge.net/p/xsltforms/mailman/message/31428268/ Regards, - Bill De: Isidro Vila Verde [mailto:jv...@gm...] Enviado el: lunes, 7 de octubre de 2013 17:28 Para: xsl...@li... Asunto: Re: [Xsltforms-support] User defined functions example Well, I think I found it myself. Looking inside xsltforms.js I found similar functions and it, apparently, does what we want XsltForms_xpathCoreFunctions['http://example.net/xforms/new-functions/ new-func'] = new XsltForms_xpathFunction( false, XsltForms_xpathFunction.DEFAULT_NONE, false, function() { return "NEW FUNC"; } ); On 10/07/2013 08:45 PM, Isidro Vila Verde wrote: I am trying to run the example presented here (http://en.wikibooks.org/wiki/XSLTForms/XSLTForms_only_Extensions#User-Defined_Functions) but the browser complains about a syntax error and, when I open the console, I see the error message: ReferenceError: XPathCoreFunctions is not defined Is that example updated to the current xsltforms version or has anyone tested it? Best regards Isidro |
From: Isidro V. V. <jv...@gm...> - 2013-10-07 22:28:08
|
Well, I think I found it myself. Looking inside xsltforms.js I found similar functions and it, apparently, does what we want XsltForms_xpathCoreFunctions['http://example.net/xforms/new-functions/ new-func'] = new XsltForms_xpathFunction( false, XsltForms_xpathFunction.DEFAULT_NONE, false, function() { return "NEW FUNC"; } ); On 10/07/2013 08:45 PM, Isidro Vila Verde wrote: > I am trying to run the example presented here > (http://en.wikibooks.org/wiki/XSLTForms/XSLTForms_only_Extensions#User-Defined_Functions) > but the browser complains about a syntax error and, when I open the > console, I see the error message: > > ReferenceError: XPathCoreFunctions is not defined > > Is that example updated to the current xsltforms version orhas anyone > tested it? > > Best regards > > Isidro > |
From: Isidro V. V. <jv...@gm...> - 2013-10-07 19:46:09
|
I am trying to run the example presented here (http://en.wikibooks.org/wiki/XSLTForms/XSLTForms_only_Extensions#User-Defined_Functions) but the browser complains about a syntax error and, when I open the console, I see the error message: ReferenceError: XPathCoreFunctions is not defined Is that example updated to the current xsltforms version orhas anyone tested it? Best regards Isidro |
From: Alain C. <ala...@ag...> - 2013-10-05 16:04:20
|
Hello Mark, This can be performed with actions and events because XForms 2.0 allows to associate properties to events: <html xmlns="http://www.w3.org/1999/xhtml" xmlns:xf="http://www.w3.org/2002/xforms" xmlns:ev="http://www.w3.org/2001/xml-events"> <head> <title>Asynchronous Javascript function call</title> <xf:model id="modelid"> <xf:instance id="instanceid" xmlns=""> <data> <latitude/> <longitude/> </data> </xf:instance> <xf:load ev:event="xforms-ready" resource="javascript:asynch()"/> <xf:action ev:event="callbackevent"> <xf:setvalue ref="latitude" value="event('latitude')"/> <xf:setvalue ref="longitude" value="event('longitude')"/> </xf:action> </xf:model> <script type="text/javascript"> function asynch() { navigator.geolocation.getCurrentPosition(show_map); } function show_map(position) { XsltForms_xmlevents.dispatch(document.getElementById("modelid"), "callbackevent", null, null, null, null, { latitude: position.coords.latitude, longitude: position.coords.longitude }); } </script> </head> <body> <xf:output value="latitude"> <xf:label>Latitude: </xf:label> </xf:output> <br/> <xf:output value="longitude"> <xf:label>Longitude: </xf:label> </xf:output> </body> </html> and my current location is: Latitude: 44.837789 Longitude: -0.57918 Thank you for your feedbacks! -Alain > I'm looking into whether I can inject results from the relocation API into an <xf:instance/> > I've added in a extension JS function to do the call like so: > > <script > > XPathCoreFunctions['http://example.net/xforms/new-functions/ new-func'] = > new XPathFunction( > false, > XPathFunction.DEFAULT_NONE, > false, > function() {{ > return navigator.geolocation.getCurrentPosition(show_map); > }} > ); > function show_map(position) {{ > var latitude = position.coords.latitude; > var longitude = position.coords.longitude; > alert(position.coords.latitude+","+ position.coords.longitude); > return "hello"; > }}; > </script> > > However, I don't get a return as the js calls a callback rather than waiting. Any ideas? > > Rgds, > > Mark Lawson. > |
From: Mark L. <tin...@gm...> - 2013-10-04 20:15:09
|
Hi, I'm looking into whether I can inject results from the relocation API into an <xf:instance/> I've added in a extension JS function to do the call like so: <script > XPathCoreFunctions['http://example.net/xforms/new-functions/ new-func'] = new XPathFunction( false, XPathFunction.DEFAULT_NONE, false, function() {{ return navigator.geolocation.getCurrentPosition(show_map); }} ); function show_map(position) {{ var latitude = position.coords.latitude; var longitude = position.coords.longitude; alert(position.coords.latitude+","+ position.coords.longitude); return "hello"; }}; </script> However, I don't get a return as the js calls a callback rather than waiting. Any ideas? Rgds, Mark Lawson. |
From: Alain C. <ala...@ag...> - 2013-09-23 06:34:56
|
Hi Eric, > I have added an instance: > > <xf:instance id="xfu-init"> > <init xmlns="">false</init> > </xf:instance> > > This instance is updated on xforms-ready: > > <xf:action ev:event="xforms-ready"> > <xf:setvalue ref="instance('xfu-init')">true</xf:setvalue> > <xf:recalculate></xf:recalculate> > <xf:refresh></xf:refresh> > </xf:action> > > And all the controls are embedded in this group: > > <xf:group ref=".[instance('xfu-init') = 'true']"> > .../... > </xf:group> > > For whatever reason, this group is never enabled! > This has been fixed in the latest build: the instance() function did not notice that the resulting node had to be considered as a dependency. Thank you for your feedbacks! -Alain |
From: Alain C. <ala...@ag...> - 2013-09-23 06:29:00
|
Hi Alexander, > i'm currently not able to access comments in a data instance (surely I'm missing a crucial point.) > > The example below gives me > > ReferenceError: comment is not defined Comments are now supported in XML instances and the comment() function has been implemented in the latest build. Thank you for your feedbacks! -Alain |
From: Alain C. <ala...@ag...> - 2013-09-20 18:45:47
|
Hi William, > I'm need to access an XForms instance from my Javascript code. I see there are several approaches mentioned on this mailing list before: > > - Submission to a Javascript function Sorry, only submission "from" a Javascript function (GET method) is currently implemented in XSLTForms > - xf:load with javascript:function on the resource attribute > - onclick event on a plain HTML button > > For the last two, this code used to work for getting an instance as a Javascript Object: > > var model = window.document.getElementById("modelid"); > var doc = model.getInstanceDocument("instanceid") > > On the last updates of XSLTForms, this code doesn't work anymore. Could you please send me a test case? Mine works: <html xmlns="http://www.w3.org/1999/xhtml" xmlns:xf="http://www.w3.org/2002/xforms"> <head> <title>Direct Access</title> <xf:model id="modelid"> <xf:instance id="instanceid" xmlns=""> <data>dummy</data> </xf:instance> </xf:model> <script type="text/javascript"> function directaccess() { var model = window.document.getElementById("modelid"); var doc = model.getInstanceDocument("instanceid"); return doc.documentElement.textContent; } </script> </head> <body> <xf:output value="directaccess()"/> </body> </html> Thanks! -Alain |
From: William V. <wve...@vi...> - 2013-09-19 23:33:54
|
Hi XForms geeks! I'm need to access an XForms instance from my Javascript code. I see there are several approaches mentioned on this mailing list before: - Submission to a Javascript function - xf:load with javascript:function on the resource attribute - onclick event on a plain HTML button For the last two, this code used to work for getting an instance as a Javascript Object: var model = window.document.getElementById("modelid"); var doc = model.getInstanceDocument("instanceid") On the last updates of XSLTForms, this code doesn't work anymore. I think the right way of doing it is with a submission to javascript:function() but there aren't examples available. Could somebody share an example or links to the code with the right way of doing it? Thanks, William David Velásquez Director de I+D Visión Tecnológica S.A.S. Tel: (4) 444 7292 Cel: 313 743 54 11 wve...@vi... Follow me: @williamda |
From: Alain C. <ala...@ag...> - 2013-09-19 19:35:51
|
Hi Eric, The issue is due to the document element not being added in the dependency nodeset: this testcase works if the tested node is not the document element but a subnode: <xf:instance id="xfu-init"> <init xmlns="" status="false"/> </xf:instance> <xf:action ev:event="xforms-ready"> <xf:setvalue ref="instance('xfu-init')/@status">true</xf:setvalue> <xf:recalculate></xf:recalculate> <xf:refresh></xf:refresh> </xf:action> <xf:group ref=".[instance('xfu-init')/@status = 'true']"> I will fix this as soon as possible. Thanks! -Alain Le 19/09/2013 10:26, Eric van der Vlist a écrit : > Hi Alain, > > Le vendredi 06 septembre 2013 à 16:30 +0200, Eric van der Vlist a > écrit : > >> I'll keep you updated on my progress! > A solution should be to make sure controls are in a predicable state > when xforms-ready fires so that you can then track their status. > > I have added an instance: > > <xf:instance id="xfu-init"> > <init xmlns="">false</init> > </xf:instance> > > This instance is updated on xforms-ready: > > <xf:action ev:event="xforms-ready"> > <xf:setvalue ref="instance('xfu-init')">true</xf:setvalue> > <xf:recalculate></xf:recalculate> > <xf:refresh></xf:refresh> > </xf:action> > > And all the controls are embedded in this group: > > <xf:group ref=".[instance('xfu-init') = 'true']"> > .../... > </xf:group> > > For whatever reason, this group is never enabled! > > I am testing with the build directory of your latest commit: > >> commit a7879461945997de25c848aa64f538aa713741ab >> Author: Alain Couthures <ala...@ag...> >> Date: Fri Sep 13 14:31:12 2013 +0200 >> >> Insertion of non-relevant node >> >> Signed-off-by: Alain Couthures <ala...@ag...> > (Complete repro: > http://xformsunit.org/trac/browser/sandbox/track-xforms-enable-disable-workaround.xhtml?rev=35d9c347f9a7e419cc44b306be99d147e33a4de5 ) > > Thanks, > > Eric > > |
From: Eric v. d. V. <vd...@dy...> - 2013-09-19 08:26:29
|
Hi Alain, Le vendredi 06 septembre 2013 à 16:30 +0200, Eric van der Vlist a écrit : > I'll keep you updated on my progress! A solution should be to make sure controls are in a predicable state when xforms-ready fires so that you can then track their status. I have added an instance: <xf:instance id="xfu-init"> <init xmlns="">false</init> </xf:instance> This instance is updated on xforms-ready: <xf:action ev:event="xforms-ready"> <xf:setvalue ref="instance('xfu-init')">true</xf:setvalue> <xf:recalculate></xf:recalculate> <xf:refresh></xf:refresh> </xf:action> And all the controls are embedded in this group: <xf:group ref=".[instance('xfu-init') = 'true']"> .../... </xf:group> For whatever reason, this group is never enabled! I am testing with the build directory of your latest commit: > commit a7879461945997de25c848aa64f538aa713741ab > Author: Alain Couthures <ala...@ag...> > Date: Fri Sep 13 14:31:12 2013 +0200 > > Insertion of non-relevant node > > Signed-off-by: Alain Couthures <ala...@ag...> (Complete repro: http://xformsunit.org/trac/browser/sandbox/track-xforms-enable-disable-workaround.xhtml?rev=35d9c347f9a7e419cc44b306be99d147e33a4de5 ) Thanks, Eric |
From: Alexander H. <al...@ho...> - 2013-09-17 07:34:27
|
Hi Alain, thanks for your feedback! There is no hurry (thanks for asking ;-), I just wanted to make sure I'm not missing something. For my use case, I can change the data source. I'm, however and in general, interested in the support of comments. Thanks for your efforts! Alex On 16.09.2013, at 22:24, Alain Couthures <ala...@ag...> wrote: > Hi Alexander, > > Comments in instances are currently removed by the XSLT stylesheet and > the comment() function is not defined. > > But I have already prototyped support for them and I will have now to > check if everything is OK with this. > > Are you in a hurry? > > Thanks! > > -Alain > > Le 16/09/2013 15:24, Alexander Holupirek a écrit : >> Hi all, >> >> i'm currently not able to access comments in a data instance (surely I'm missing a crucial point.) >> >> The example below gives me >> >> ReferenceError: comment is not defined >> >> Example: >> >> <?xml version="1.0" encoding="iso-8859-1"?> >> <?xml-stylesheet href="xsltforms/xsltforms.xsl" type="text/xsl"?> >> <?xsltforms-options debug="no"?> >> <html xmlns="http://www.w3.org/1999/xhtml" >> xmlns:h="http://www.w3.org/1999/xhtml" >> xmlns:ev="http://www.w3.org/2001/xml-events" >> xmlns:xsd="http://www.w3.org/2001/XMLSchema" >> xmlns:xf="http://www.w3.org/2002/xforms"> >> <head> >> <title>Acessing comments?</title> >> <style type="text/css"> >> body { font-family: sans-serif} >> label { display: inline-block; width: 8em; margin: 0 1em; text-align: right } >> </style> >> <model xmlns="http://www.w3.org/2002/xforms"> >> <instance> >> <data xmlns=""> >> <!-- Comment A --> >> <a>A</a> >> <!-- Comment B --> >> <b>B</b> >> <!-- Comment C --> >> <c>C</c> >> </data> >> </instance> >> </model> >> </head> >> <body> >> <xf:repeat nodeset="node()"> >> <xf:output value="string(.)"/> >> </xf:repeat> >> <xf:repeat nodeset="comment()"> >> <xf:output value="string(.)"/> >> </xf:repeat> >> </body> >> </html> >> >> Can someone please enlighten me? >> >> Thanks a lot, >> Alex >> ------------------------------------------------------------------------------ >> LIMITED TIME SALE - Full Year of Microsoft Training For Just $49.99! >> 1,500+ hours of tutorials including VisualStudio 2012, Windows 8, SharePoint >> 2013, SQL 2012, MVC 4, more. BEST VALUE: New Multi-Library Power Pack includes >> Mobile, Cloud, Java, and UX Design. Lowest price ever! Ends 9/20/13. >> http://pubads.g.doubleclick.net/gampad/clk?id=58041151&iu=/4140/ostg.clktrk >> _______________________________________________ >> Xsltforms-support mailing list >> Xsl...@li... >> https://lists.sourceforge.net/lists/listinfo/xsltforms-support >> > > > ------------------------------------------------------------------------------ > LIMITED TIME SALE - Full Year of Microsoft Training For Just $49.99! > 1,500+ hours of tutorials including VisualStudio 2012, Windows 8, SharePoint > 2013, SQL 2012, MVC 4, more. BEST VALUE: New Multi-Library Power Pack includes > Mobile, Cloud, Java, and UX Design. Lowest price ever! Ends 9/20/13. > http://pubads.g.doubleclick.net/gampad/clk?id=58041151&iu=/4140/ostg.clktrk > _______________________________________________ > Xsltforms-support mailing list > Xsl...@li... > https://lists.sourceforge.net/lists/listinfo/xsltforms-support -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- Alexander Holupirek |-- Mosbrugger Strasse 9 |-- 78462 Konstanz `-- 07531 80 4 80 65 / 0176 600 25 949 |
From: Alain C. <ala...@ag...> - 2013-09-16 20:37:22
|
Hi Alexander, Comments in instances are currently removed by the XSLT stylesheet and the comment() function is not defined. But I have already prototyped support for them and I will have now to check if everything is OK with this. Are you in a hurry? Thanks! -Alain Le 16/09/2013 15:24, Alexander Holupirek a écrit : > Hi all, > > i'm currently not able to access comments in a data instance (surely I'm missing a crucial point.) > > The example below gives me > > ReferenceError: comment is not defined > > Example: > > <?xml version="1.0" encoding="iso-8859-1"?> > <?xml-stylesheet href="xsltforms/xsltforms.xsl" type="text/xsl"?> > <?xsltforms-options debug="no"?> > <html xmlns="http://www.w3.org/1999/xhtml" > xmlns:h="http://www.w3.org/1999/xhtml" > xmlns:ev="http://www.w3.org/2001/xml-events" > xmlns:xsd="http://www.w3.org/2001/XMLSchema" > xmlns:xf="http://www.w3.org/2002/xforms"> > <head> > <title>Acessing comments?</title> > <style type="text/css"> > body { font-family: sans-serif} > label { display: inline-block; width: 8em; margin: 0 1em; text-align: right } > </style> > <model xmlns="http://www.w3.org/2002/xforms"> > <instance> > <data xmlns=""> > <!-- Comment A --> > <a>A</a> > <!-- Comment B --> > <b>B</b> > <!-- Comment C --> > <c>C</c> > </data> > </instance> > </model> > </head> > <body> > <xf:repeat nodeset="node()"> > <xf:output value="string(.)"/> > </xf:repeat> > <xf:repeat nodeset="comment()"> > <xf:output value="string(.)"/> > </xf:repeat> > </body> > </html> > > Can someone please enlighten me? > > Thanks a lot, > Alex > ------------------------------------------------------------------------------ > LIMITED TIME SALE - Full Year of Microsoft Training For Just $49.99! > 1,500+ hours of tutorials including VisualStudio 2012, Windows 8, SharePoint > 2013, SQL 2012, MVC 4, more. BEST VALUE: New Multi-Library Power Pack includes > Mobile, Cloud, Java, and UX Design. Lowest price ever! Ends 9/20/13. > http://pubads.g.doubleclick.net/gampad/clk?id=58041151&iu=/4140/ostg.clktrk > _______________________________________________ > Xsltforms-support mailing list > Xsl...@li... > https://lists.sourceforge.net/lists/listinfo/xsltforms-support > |
From: Alexander H. <al...@ho...> - 2013-09-16 13:37:45
|
Hi all, i'm currently not able to access comments in a data instance (surely I'm missing a crucial point.) The example below gives me ReferenceError: comment is not defined Example: <?xml version="1.0" encoding="iso-8859-1"?> <?xml-stylesheet href="xsltforms/xsltforms.xsl" type="text/xsl"?> <?xsltforms-options debug="no"?> <html xmlns="http://www.w3.org/1999/xhtml" xmlns:h="http://www.w3.org/1999/xhtml" xmlns:ev="http://www.w3.org/2001/xml-events" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xf="http://www.w3.org/2002/xforms"> > <head> <title>Acessing comments?</title> <style type="text/css"> body { font-family: sans-serif} label { display: inline-block; width: 8em; margin: 0 1em; text-align: right } </style> <model xmlns="http://www.w3.org/2002/xforms"> <instance> <data xmlns=""> <!-- Comment A --> <a>A</a> <!-- Comment B --> <b>B</b> <!-- Comment C --> <c>C</c> </data> </instance> </model> </head> <body> <xf:repeat nodeset="node()"> <xf:output value="string(.)"/> </xf:repeat> <xf:repeat nodeset="comment()"> <xf:output value="string(.)"/> </xf:repeat> </body> </html> Can someone please enlighten me? Thanks a lot, Alex |
From: Alain C. <ala...@ag...> - 2013-09-13 12:51:20
|
Bonjour Ioan, > >> >> I found this problem in the latest version - 578. Can be checked at >> any variant of insert. In the previous version that I tried it - 559 >> - this worked properly. >> >> Drawback is especially noticeable in Chrome, which gives the error >> message: >> >> " Uncaught TypeError: Cannot read property 'length' of undefined " >> >> > Does Chrome give you a line number in xsltforms.js? > > This surely sounds like some property test missing... > > I have now added the required tests in the latest build so this should not occur anymore. Thank you for your feedbacks! -Alain |
From: Alain C. <ala...@ag...> - 2013-09-10 19:19:41
|
Bonjour Ioan, > > I found this problem in the latest version - 578. Can be checked at > any variant of insert. In the previous version that I tried it - 559 - > this worked properly. > > Drawback is especially noticeable in Chrome, which gives the error > message: > > " Uncaught TypeError: Cannot read property 'length' of undefined " > > Does Chrome give you a line number in xsltforms.js? This surely sounds like some property test missing... Merci d'avance -Alain |
From: Ioan F. <mi...@gm...> - 2013-09-10 08:26:31
|
Bonjour Alain, I found this problem in the latest version - 578. Can be checked at any variant of insert. In the previous version that I tried it - 559 - this worked properly. Drawback is especially noticeable in Chrome, which gives the error message: " Uncaught TypeError: Cannot read property 'length' of undefined " Merci beaucoup! Ioan |
From: Eric v. d. V. <vd...@dy...> - 2013-09-09 13:45:21
|
Alain, You're 100% right, how can I have understood the opposite when that's so clearly written? I need more sleep (or more coffee), sorry for the noise... Thanks, Eric PS: Now I need to fill a bug for betterFORM! Le dimanche 08 septembre 2013 à 21:26 +0200, Alain Couthures a écrit : > Eric, > > > From my point of view, the incremental mode is the default one for > > > select/select1 controls and, as a consequence, a rebuild can occur > > > before the focus being lost. > > Yes, that's also the default for Orbeon Forms and it seems much more > > natural that way. Unfortunately, my understanding of the recommendation > > is that this should not be the case... > > > > > I have checked the event sequence with test 4.6.3.a and it is passed (I > > > had first to fix an issue about inserting a non relevant node resulting > > > in a new relevant node... I have committed another build for this fix). > > > > > > What do you think? > > IMHO, that boils down to decide if you prefer to be conformant to the > > recommendation or do what seems natural ;) ... > > > > I tend to think that being conformant to the recommendation should win > > but that's a hard decision to take! > Sorry, could you please be more explicit about for which part of the > recommendation Orbeon Forms and XSLTForms are not compliant? > > From my point of view, incremental="true" "is the default for the > select or select1 elements" as mentioned at: > > 4.6.3 For select or select1 Controls > * When a selection is interactively changed, and the form > control has the incremental="true" setting (which is the > default for the select or select1 elements), the event > sequence is described at 4.6.6 Sequence: Selection Without > Value Change, which may be followed immediately by the > sequence described at 4.6.7 Sequence: Value Change. > > Thanks! > > -Alain |
From: Alain C. <ala...@ag...> - 2013-09-08 19:39:35
|
Eric, >> From my point of view, the incremental mode is the default one for >> select/select1 controls and, as a consequence, a rebuild can occur >> before the focus being lost. > Yes, that's also the default for Orbeon Forms and it seems much more > natural that way. Unfortunately, my understanding of the recommendation > is that this should not be the case... > >> I have checked the event sequence with test 4.6.3.a and it is passed (I >> had first to fix an issue about inserting a non relevant node resulting >> in a new relevant node... I have committed another build for this fix). >> >> What do you think? > IMHO, that boils down to decide if you prefer to be conformant to the > recommendation or do what seems natural ;) ... > > I tend to think that being conformant to the recommendation should win > but that's a hard decision to take! Sorry, could you please be more explicit about for which part of the recommendation Orbeon Forms and XSLTForms are not compliant? From my point of view, incremental="true" "*is the default for the select or select1 elements*" as mentioned at: 4.6.3 For |select| or |select1| Controls * When a selection is interactively changed, and the form control has the |incremental="true"| setting (*which is the default for the **|select|**or **|select1|**elements*), the event sequence is described at *4.6.6 Sequence: Selection Without Value Change* <http://www.w3.org/TR/xforms/#rpm-event-seq-swovc>, which may be followed immediately by the sequence described at *4.6.7 Sequence: Value Change* <http://www.w3.org/TR/xforms/#rpm-event-seq-vc>. Thanks! -Alain |
From: Eric v. d. V. <vd...@dy...> - 2013-09-07 19:50:59
|
Alain, Le samedi 07 septembre 2013 à 21:43 +0200, Alain Couthures a écrit : > Hello Eric, > > From my point of view, the incremental mode is the default one for > select/select1 controls and, as a consequence, a rebuild can occur > before the focus being lost. Yes, that's also the default for Orbeon Forms and it seems much more natural that way. Unfortunately, my understanding of the recommendation is that this should not be the case... > I have checked the event sequence with test 4.6.3.a and it is passed (I > had first to fix an issue about inserting a non relevant node resulting > in a new relevant node... I have committed another build for this fix). > > What do you think? IMHO, that boils down to decide if you prefer to be conformant to the recommendation or do what seems natural ;) ... I tend to think that being conformant to the recommendation should win but that's a hard decision to take! Thanks, Eric > -Alain |
From: Eric v. d. V. <vd...@dy...> - 2013-09-07 19:44:27
|
Hi Alain, Le vendredi 06 septembre 2013 à 14:09 +0200, Alain Couthures a écrit : > Hello Eric, > > Support of xf:recalculate has been added in latest builds of XSLTForms > and the test case is now successfully passed. That's working for me too. To run my "hello world suite" [1] I am now hitting the issue of namespaces on Firefox which is well documented here: http://en.wikibooks.org/wiki/XSLTForms/Known_Restrictions and that gives me another reason to drop namespaces from the vocabulary used to describe the suite as discussed after my announcement [2]! Thanks, Eric [1] http://xformsunit.org/trac/browser/resources/apps/xformsunit/suites/hello-world/suite.xml [2] http://xformsunit.org/2013/08/23/a-vocabulary-to-describe-test-suites/ > Thank you for your feedbacks! > > -Alain > |
From: Alain C. <ala...@ag...> - 2013-09-07 19:44:00
|
Hello Eric, From my point of view, the incremental mode is the default one for select/select1 controls and, as a consequence, a rebuild can occur before the focus being lost. I have checked the event sequence with test 4.6.3.a and it is passed (I had first to fix an issue about inserting a non relevant node resulting in a new relevant node... I have committed another build for this fix). What do you think? -Alain Le 23/08/2013 15:38, Eric van der Vlist a écrit : > Hi, > > If you try: > <?xml version="1.0" encoding="utf-8"?> > <?xml-stylesheet href="xsltforms.xsl" type="text/xsl"?> > <?xsltforms-options debug="yes"?> > <html xmlns="http://www.w3.org/1999/xhtml" > xmlns:xf="http://www.w3.org/2002/xforms" > xmlns:ev="http://www.w3.org/2001/xml-events"> > <head> > <title>Hello World in XForms</title> > <xf:model id="model"> > <xf:instance id="instance" xmlns=""> > <data> > <PersonGivenName></PersonGivenName> > <show>control-1</show> > </data> > </xf:instance> > <xf:instance id="controls" xmlns=""> > <controls> > <control-1>disabled</control-1> > <control-2>disabled</control-2> > </controls> > </xf:instance> > </xf:model> > </head> > <body> > <xf:select ref="show" appearance="full"> > <xf:label>Display: </xf:label> > <xf:item> > <xf:label>control-1</xf:label> > <xf:value>control-1</xf:value> > </xf:item> > <xf:item> > <xf:label>control-2</xf:label> > <xf:value>control-2</xf:value> > </xf:item> > </xf:select> > <br /> > <xf:group ref="instance('controls')"> > <xf:output ref="control-1"> > <xf:label>control-1</xf:label> > </xf:output> > <xf:output ref="control-2"> > <xf:label>control-2</xf:label> > </xf:output> > </xf:group> > <br /> > <xf:input ref="PersonGivenName[contains(../show, 'control-1')]"> > <xf:label>control-1 :</xf:label> > <xf:message ev:event="xforms-enabled">Coucou</xf:message> > <xf:setvalue ev:event="xforms-enabled" > ref="instance('controls')/control-1">enabled</xf:setvalue> > <xf:setvalue ev:event="xforms-disabled" > ref="instance('controls')/control-1">disabled</xf:setvalue> > </xf:input> > <br /> > <xf:input ref="PersonGivenName[contains(../show, 'control-2')]"> > <xf:label>control-2 :</xf:label> > <xf:setvalue ev:event="xforms-enabled" > ref="instance('controls')/control-2">enabled</xf:setvalue> > <xf:setvalue ev:event="xforms-disabled" > ref="instance('controls')/control-2">disabled</xf:setvalue> > </xf:input> > </body> > </html> > > You'll see that the controls control-1 and control-2 are > displayed/hidden immediately after the selection is changed, before the > focus leaves the xf:select which is not what is described in the > recommendation (http://www.w3.org/TR/xforms11/#sequence-for-select ) > > Thanks, > > Eric > > > > ------------------------------------------------------------------------------ > Introducing Performance Central, a new site from SourceForge and > AppDynamics. Performance Central is your source for news, insights, > analysis and resources for efficient Application Performance Management. > Visit us today! > http://pubads.g.doubleclick.net/gampad/clk?id=48897511&iu=/4140/ostg.clktrk > _______________________________________________ > Xsltforms-support mailing list > Xsl...@li... > https://lists.sourceforge.net/lists/listinfo/xsltforms-support > |
From: Alain C. <ala...@ag...> - 2013-09-06 19:16:56
|
Hello Eric, I have successfully tested this with a resource in the same domain and with the latest build. I recently had to rename the binding.evaluate() method and I would like to know which release you have been using. BTW, I wonder if the cross-domain restriction occurred for you, the form being at file:///home/vdv/projects/xsltforms-code/build while the resource being at http://localhost:8088/exist/apps/betterform/sandbox This is a limitation for any Javascript implementation within a browser... What do you think? -Alain Le 24/08/2013 11:44, Eric van der Vlist a écrit : > Hi, > > The following form: > > <?xml version="1.0" encoding="utf-8"?> > <?xml-stylesheet href="xsltforms.xsl" type="text/xsl"?> > <?xsltforms-options debug="yes"?> > <html xmlns="http://www.w3.org/1999/xhtml" > xmlns:xf="http://www.w3.org/2002/xforms" > xmlns:ev="http://www.w3.org/2001/xml-events" > > <head> > <title>Submission on xforms-ready</title> > <xf:model id="model"> > <xf:instance id="instance"> > <data xmlns="">Whatever</data> > </xf:instance> > > <xf:submission id="echo" ref="instance('instance')" > method="POST" > > action="http://localhost:8088/exist/apps/betterform/sandbox/echo.xq" > replace="all"/> > > <xf:send ev:event="xforms-ready" submission="echo"/> > > </xf:model> > </head> > <body> </body> > </html> > > Where echo.xq is: > > xquery version "1.0"; > > (: echo-post.xq: Return all data from an HTTP post to the caller. :) > > declare namespace exist = "http://exist.sourceforge.net/NS/exist"; > declare namespace xmldb="http://exist-db.org/xquery/xmldb"; > declare namespace request="http://exist-db.org/xquery/request"; > > declare option exist:serialize "method=xml media-type=text/xml > indent=yes"; > > let $post-data := request:get-data() > > return > <post-data> > {$post-data} > </post-data> > > Raises the following error: > > XSLTForms Exception > -------------------------- > > Error dispatching event 'xforms-submit' : > > @file:///home/vdv/projects/xsltforms-code/build/xsltforms.js:4403 > XsltForms_submission.prototype.submit@file:///home/vdv/projects/xsltforms-code/build/xsltforms.js:4445 > @file:///home/vdv/projects/xsltforms-code/build/xsltforms.js:10197 > XsltForms_xmlevents.dispatch@file:///home/vdv/projects/xsltforms-code/build/xsltforms.js:10106 > XsltForms_dispatch.prototype.run@file:///home/vdv/projects/xsltforms-code/build/xsltforms.js:5240 > XsltForms_abstractAction.prototype.exec_@file:///home/vdv/projects/xsltforms-code/build/xsltforms.js:5084 > XsltForms_abstractAction.prototype.execute@file:///home/vdv/projects/xsltforms-code/build/xsltforms.js:5069 > XsltForms_browser.run@file:///home/vdv/projects/xsltforms-code/build/xsltforms.js:2778 > @file:///home/vdv/projects/xsltforms-code/build/suite.xml:26 > @file:///home/vdv/projects/xsltforms-code/build/xsltforms.js:9983 > XsltForms_xmlevents.dispatch@file:///home/vdv/projects/xsltforms-code/build/xsltforms.js:10104 > XsltForms_xmlevents.dispatchList@file:///home/vdv/projects/xsltforms-code/build/xsltforms.js:10075 > @file:///home/vdv/projects/xsltforms-code/build/xsltforms.js:3282 > > > TypeError > > this.binding.evaluate(...) is undefined > > > Thanks, > > Eric > > > ------------------------------------------------------------------------------ > Introducing Performance Central, a new site from SourceForge and > AppDynamics. Performance Central is your source for news, insights, > analysis and resources for efficient Application Performance Management. > Visit us today! > http://pubads.g.doubleclick.net/gampad/clk?id=48897511&iu=/4140/ostg.clktrk > _______________________________________________ > Xsltforms-support mailing list > Xsl...@li... > https://lists.sourceforge.net/lists/listinfo/xsltforms-support > |