Get a form action/url with jquery

Dejan.S picture Dejan.S · Apr 11, 2011 · Viewed 76.1k times · Source

How do I get the action url from a form with jquery?

Answer

JAAulde picture JAAulde · Apr 11, 2011

Get the form, ask for the action attribute:

$('#myForm').attr('action');