| Page 1 of 1 | [ 7 posts ] |
|
Hello,
When I submit a form with io-form with method POST, it works the first time, but if I submit my form twice, all the values are duplicated in the post request. I wrote a minimal php / javascript code you can see at the address http://www.kitpages.fr/test/yui3/io.php - When you click the first time on the submit button the alert is ok with the good parameter. - The second time I submit the form, the parameter sent by the post request is sent twice (you can see it in firebug or the debugBar). - The third time, the parameter is sent three times and so on. I believe it is a bug in io or io-form, but I'm not sure. Can you check the code and tell me if I made a mistake. Best regards, Philippe (I tested that with macos FF3 and IE8) |
|
The issue was reported and logged as ticket 2528307. It was resolved in build yui3-1557, specifically io-base.js. Please pull the build from development master from our project on GitHub for the resolution.
Regards, Thomas |
|
Thanks for your answer and the correction ! (I didn't find the good ticket, sorry...)
|
|
i also met this problem
YUI, Why not Use In your project?
and i download the fix version of yui from github but when i post form use Y.io the request yet had been sent twice anyone has a good idea? |
|
Please post a complete code example that reproduces this problem.
Regards, Thomas |
|
Code: <?php if (validation_errors ()) { echo "<div id='errors'>"; echo validation_errors (); echo "</div>"; } ?> <div id='formcontent' class=""> <?php echo $form; ?> </div> <div id='jscontent' style='display:none;'> YUI({combine:false, timeout:100000,base:'/system/application/js/yui/'}).use('io','node', function(Y){ var d = document.getElementById('content'); var Callback = { start:function(){}, success:function(ioID, o){ d.innerHTML = o.responseText; }, failure:function(ioID, o){ d.innerHTML = o.responseText; }, end:function(ioID, o){ Y.on('click', call, '#submitform', this); } }; var cfg = { method:'POST', on:{ start:Callback.start, success:Callback.success, failure:Callback.failure, end:Callback.end }, content:Callback, form:{ id:'newArticleCategory', useDisabled:true }, headers:{'X-Transaction':'POST Example'} }; function call(e){ Y.io('/admin/newArticleCategory', cfg); }; Y.on('click', call, '#submitform', this); }); </div> just as above, the new article page was called by another Y.io when i first submited this form, it run correctly but when i want to add a new record, it posted twice |
|
i am on YUI 3.4.1
if found this ticket http://yuilibrary.com/projects/yui3/ticket/2528307 ticket says target release as 3.1.0 when i submit form the radio button type fields gets duplicated. one field has proper value other gets undefined. i guess this issue is not completely fixed. |
| Page 1 of 1 | [ 7 posts ] |
| You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum |
© 2006-2013 Yahoo! Inc. All rights reserved.
All code on this site is licensed under the BSD License unless stated otherwise.
About This Site · Security Contact Info
Powered by phpBB® Forum Software © phpBB Group