tags:

views:

25

answers:

1

Lets say the URL in my form is

action="/medias/new_from_disk?CKEditor=content_body&CKEditorFuncNum=1&langCode=en"

and the form has ID myform how would I conjure a jQuery command to add to the action

&var=value

?

complete form:

<form enctype="multipart/form-data"
       id="myform"
       method="POST" 
       action="/medias/new_from_disk?CKEditor=content_body&amp;CKEditorFuncNum=1&amp;langCode=en">
 </form>
+1  A: 

Like this:

$('#myform').attr('action', $('#myform').attr('action') + '&var=value');

More Info:

Sarfraz