I a writing a pic upload script. The script moves the picture to a directory and also puts it into a database. I want to return the directory of this script to my Jquery function, and So I can then add it to a <iframe> or whatever. I hope that I am running the script, but I am not sure if that is indeed occurring. To make sure, how do I get the return value of a php function which is called by an $(jquery).Ajax() call?
-
$.ajax() will pass to your callback all the server-side script outputs. (In PHP, using echo, <?= ?>…)millimoose– millimoose2011-09-29 01:21:32 +00:00Commented Sep 29, 2011 at 1:21
Add a comment
|
2 Answers
I would suggest using google next time and also reading official manuals..
http://api.jquery.com/jQuery.ajax/
good luck!
this is what you are looking for.
$.ajax({
success: function(data, textStatus, jqXHR){}
});