Hi Adam,
> Looking at xsltforms.js, the line in
> XsltForms_submission.prototype.submit that invokes JS is this one:
>
>      eval("ser = (" + action.substr(11) + ");");
>
> So my work-around is to make the garbage appended to the action
> harmless by making it a comment:
>
> <xf:submission
>          id='submit'
>          method='get'
>          relevant='true'
>          replace='instance'
>          serialization='application/xml'
>          action='javascript:submit(ser));//'
> />
>
> The line of JS eval'd might be something like:
>
>      ser = (submit(ser));//?var1=val1&var2=val2...
By default, XSLTForms is serializing the current instance with a get 
method in the query string:

         if ((method === "get" || method === "delete") && 
this.serialization !== "none" && action.substr(0, 9) !== "opener://" && 
action.substr(0, 8) !== "local://") {
             var tourl = XsltForms_submission.toUrl_(node, this.separator);
             action += (action.indexOf('?') === -1? '?' : this.separator) +
                 tourl.substr(0, tourl.length - this.separator.length);
         }

The test condition could be extended for Javascript: && 
action.substr(0,11) !== "javascript:"

Could you please test with this?
> Also, can XSLTForms co-exist with jQuery now?  Currently I put my
> forms into iframes, which is mostly OK, but it would be nice in future
> to have everything in one integrated page.
>
I think that some XSLTForms users have already mixed it with jQuery. Do 
you have a test case which doesn't work?

Thanks!

-Alain

------------------------------------------------------------------------------
Own the Future-Intel&reg; Level Up Game Demo Contest 2013
Rise to greatness in Intel's independent game demo contest.
Compete for recognition, cash, and the chance to get your game 
on Steam. $5K grand prize plus 10 genre and skill prizes. 
Submit your demo by 6/6/13. http://p.sf.net/sfu/intel_levelupd2d
_______________________________________________
Xsltforms-support mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/xsltforms-support

Reply via email to