Welcome Guest, Not a member yet? Register   Sign In
Sending data via AJAX request
#1

[eluser]Unknown[/eluser]
Hello,
I'm unable to send data to controller via AJAX request. I have this code:
Code:
$.ajax({
                type: "POST",
                    url: "controller/method",
                    dataType: "html",
                    data: ({'key' : 'value'}),
                    success: function( data ) {
                        alert( data );
                    }
                });

Ajax response handler throws error code 500 and no data are returned.
It works fine when making request without additional data (parameter data).

Any idea?

Thank you.


Messages In This Thread
Sending data via AJAX request - by El Forum - 03-07-2011, 12:25 PM
Sending data via AJAX request - by El Forum - 03-07-2011, 12:58 PM
Sending data via AJAX request - by El Forum - 03-07-2011, 01:59 PM



Theme © iAndrew 2016 - Forum software by © MyBB