Thread: [Xsltforms-support] transforms on an instance.
Brought to you by:
alain-couthures
From: Ihe O. <ihe...@gm...> - 2012-11-22 14:31:35
|
I need to do transformations, both pre and post on data in my XForms instance. Actually I could transform before loading but I need to transform after the user edits the XForm as well. I've come across bits and bobs suggesting you can load a stylesheet into an instance. Could somebody direct me to where I can get more info on how to accomplish this. Also are such transforms XSLT 1.0 or 2.0. I am running XSLTForms from eXist. thanks |
From: Alain C. <ala...@ag...> - 2012-11-22 21:24:11
|
Hello Ihe, > I need to do transformations, both pre and post on data in my XForms > instance. Actually I could transform before loading but I need to > transform after the user edits the XForm as well. > > I've come across bits and bobs suggesting you can load a stylesheet > into an instance. Could somebody direct me to where I can get more > info on how to accomplish this. Have a look at http://www.agencexml.com/xsltforms/survey.xml This is a new example I just added to demonstrate CSV submission with XSLT preprocessing. > > Also are such transforms XSLT 1.0 or 2.0. I am running XSLTForms from eXist. Because the XSLT engine is the one of the browser, this is XSLT 1.0. Thank you for you feedbacks! -Alain |
From: Stephen C. <ste...@gm...> - 2012-11-22 22:31:40
|
Hi Ihe, There is also an non-standard 'setnode' XPath action that is useful in this scenario. there is an example form here: http://www.mail-archive.com/xsl...@li.../msg00331.html but I've used it thus: <xf:setnode ref="instance('xform')" outer="transform(instance('built_schema'),'xslt/generator_1.0.xsl')"/> Cheers On Fri, Nov 23, 2012 at 1:31 AM, Ihe Onwuka <ihe...@gm...> wrote: > I need to do transformations, both pre and post on data in my XForms > instance. Actually I could transform before loading but I need to > transform after the user edits the XForm as well. > > I've come across bits and bobs suggesting you can load a stylesheet > into an instance. Could somebody direct me to where I can get more > info on how to accomplish this. > > Also are such transforms XSLT 1.0 or 2.0. I am running XSLTForms from > eXist. > > thanks > > > ------------------------------------------------------------------------------ > Monitor your physical, virtual and cloud infrastructure from a single > web console. Get in-depth insight into apps, servers, databases, vmware, > SAP, cloud infrastructure, etc. Download 30-day Free Trial. > Pricing starts from $795 for 25 servers or applications! > http://p.sf.net/sfu/zoho_dev2dev_nov > _______________________________________________ > Xsltforms-support mailing list > Xsl...@li... > https://lists.sourceforge.net/lists/listinfo/xsltforms-support > |
From: Florent G. <li...@fg...> - 2012-11-24 15:00:26
|
Alain Couthures wrote: Hi Alain, > Because the XSLT engine is the one of the browser, this is XSLT 1.0. By the way, have you considered migrating to (or having an alternative version for) Saxon CE? Regards, -- Florent Georges http://fgeorges.org/ http://h2oconsulting.be/ |
From: Alain C. <ala...@ag...> - 2012-11-24 21:00:16
|
Hi Florent, > >> Because the XSLT engine is the one of the browser, this is XSLT 1.0. > By the way, have you considered migrating to (or having an alternative version for) Saxon CE? There is an issue for Saxon CE as main XSLT engine for XSLTForms: browsers don't want adjacent text nodes in generated SCRIPT elements. Even if XSLTForms could easily be modified for this, performance is not good. As an engine for the transform() function, the performance issue might be acceptable but I did not succeed in using the API for this use case... -Alain |
From: Florent G. <li...@fg...> - 2012-11-25 15:11:59
|
Alain Couthures wrote: Hi, >> By the way, have you considered migrating to (or having an >> alternative version for) Saxon CE? > There is an issue for Saxon CE as main XSLT engine for > XSLTForms: browsers don't want adjacent text nodes in generated > SCRIPT elements. Even if XSLTForms could easily be modified > for this, performance is not good. Thanks for the details. Too bad for the performance issue. But maybe if there was a version using CE, it would be a good use case for Saxonica to invest time in performance tuning? ;-) Regards, -- Florent Georges http://fgeorges.org/ http://h2oconsulting.be/ |
From: Ihe O. <ihe...@gm...> - 2012-11-27 13:11:08
|
Could somebody explain what the inner and outer attributes of setnode do. I set up and ran the example in CSM's message and it didn't do anything?. On Thu, Nov 22, 2012 at 10:31 PM, Stephen Cameron <ste...@gm...> wrote: > Hi Ihe, > > There is also an non-standard 'setnode' XPath action that is useful in this > scenario. > > there is an example form here: > http://www.mail-archive.com/xsl...@li.../msg00331.html > > but I've used it thus: > > <xf:setnode ref="instance('xform')" > outer="transform(instance('built_schema'),'xslt/generator_1.0.xsl')"/> > > Cheers > > > On Fri, Nov 23, 2012 at 1:31 AM, Ihe Onwuka <ihe...@gm...> wrote: >> >> I need to do transformations, both pre and post on data in my XForms >> instance. Actually I could transform before loading but I need to >> transform after the user edits the XForm as well. >> >> I've come across bits and bobs suggesting you can load a stylesheet >> into an instance. Could somebody direct me to where I can get more >> info on how to accomplish this. >> >> Also are such transforms XSLT 1.0 or 2.0. I am running XSLTForms from >> eXist. >> >> thanks >> >> >> ------------------------------------------------------------------------------ >> Monitor your physical, virtual and cloud infrastructure from a single >> web console. Get in-depth insight into apps, servers, databases, vmware, >> SAP, cloud infrastructure, etc. Download 30-day Free Trial. >> Pricing starts from $795 for 25 servers or applications! >> http://p.sf.net/sfu/zoho_dev2dev_nov >> _______________________________________________ >> Xsltforms-support mailing list >> Xsl...@li... >> https://lists.sourceforge.net/lists/listinfo/xsltforms-support > > > > ------------------------------------------------------------------------------ > Monitor your physical, virtual and cloud infrastructure from a single > web console. Get in-depth insight into apps, servers, databases, vmware, > SAP, cloud infrastructure, etc. Download 30-day Free Trial. > Pricing starts from $795 for 25 servers or applications! > http://p.sf.net/sfu/zoho_dev2dev_nov > _______________________________________________ > Xsltforms-support mailing list > Xsl...@li... > https://lists.sourceforge.net/lists/listinfo/xsltforms-support > |
From: Alain C. <ala...@ag...> - 2012-11-27 21:03:04
|
Hello Ihe, > Could somebody explain what the inner and outer attributes of setnode do. > > It's like with .innerHTML and .outerHTML: @inner will replace the node content and @outer will replace the node itself. -Alain |