[eluser]Unknown[/eluser]
Quote:< script >
$(document).ready(function() {
$('#myForm').submit(function() {
$.ajax({
type: 'POST',
url: $(this).attr('action'),
data: $(this).serialize(),
success: function(data) {
$('#result').html(data);
}
})
return false;
});
})
< / script >
<form id="myForm" method="post" action="xxx">
</form>
<div id="result"></div>
i want action of "myForm" linked to another IP.
example : My IP : 192.168.1.1
i want the action linked to 192.168.1.2
it works if i dont't use this ajax / jquery.
I added ajax code because i wanted the action of this form refered to
<div id="result"></div>, but it didn't work, why was that??, any idea?