Re: [jQuery] Quickest way to clearALL form elements after Ajax submit

2007-02-06 Thread Lquid
Well then you can clear only select elements like this. $('#FORMID [EMAIL PROTECTED]').attr('value',''); $('#FORMID [EMAIL PROTECTED]').attr('value',''); $('#FORMID [EMAIL PROTECTED]').attr('value',''); only use this approach if you have to. Its better to use the form plugin. -Lquid malsup

Re: [jQuery] Quickest way to clearALL form elements after Ajax submit

2007-02-06 Thread Klaus Hartl
Lquid schrieb: Well then you can clear only select elements like this. $('#FORMID [EMAIL PROTECTED]').attr('value',''); $('#FORMID [EMAIL PROTECTED]').attr('value',''); $('#FORMID [EMAIL PROTECTED]').attr('value',''); only use this approach if you have to. Its better to use the form

Re: [jQuery] Quickest way to clearALL form elements after Ajax submit

2007-02-06 Thread Mike Alsup
Well then you can clear only select elements like this. $('#FORMID [EMAIL PROTECTED]').attr('value',''); $('#FORMID [EMAIL PROTECTED]').attr('value',''); $('#FORMID [EMAIL PROTECTED]').attr('value',''); No, you don't want to clear the value of a checkbox or radio input. For those inputs

[jQuery] Quickest way to clearALL form elements after Ajax submit

2007-02-05 Thread Michael E. Carluen
I was wondering if anyone can remind me the quickest/easiest way to clear all form field elements after $.ajax({.success::.}); (Sorry, been a very long day, and I just been having a severe brainfart moment) Thanks!!! ___ jQuery mailing list

Re: [jQuery] Quickest way to clearALL form elements after Ajax submit

2007-02-05 Thread Linan Wang
form.reset(); On 06/02/07, Michael E. Carluen [EMAIL PROTECTED] wrote: I was wondering if anyone can remind me the quickest/easiest way to clear all form field elements after $.ajax({…success::…}); (Sorry, been a very long day, and I just been having a severe brainfart moment)

Re: [jQuery] Quickest way to clearALL form elements after Ajax submit

2007-02-05 Thread Mike Alsup
I was wondering if anyone can remind me the quickest/easiest way to clear all form field elements after $.ajax({…success::…}); (Sorry, been a very long day, and I just been having a severe brainfart moment) If you're using the form plugin you can either call the clearForm method or you can

Re: [jQuery] Quickest way to clearALL form elements after Ajax submit

2007-02-05 Thread Lquid
Or try this: $('#FORMID [EMAIL PROTECTED]').attr('value',''); I have not tested he above code for acuraccy but it should work even if you are using basic jQuery. -Lquid Michael E. Carluen wrote: I was wondering if anyone can remind me the quickest/easiest way to clear all form field

Re: [jQuery] Quickest way to clearALL form elements after Ajax submit

2007-02-05 Thread Mike Alsup
$('#FORMID [EMAIL PROTECTED]').attr('value',''); I have not tested he above code for acuraccy but it should work even if you are using basic jQuery. I would not recommend this approach. You'll clear the value from inputs that should not be cleared, such as hidden inputs, checkboxes, and