$.get("http://localhost/test.php", (function(data){
alert(data);
}))
The alert is empty. I'm new to this, and I can't see what I'm doing wrong. Help?
Perhaps you're not telling the code to run? Try putting it in $(document).ready() with
$(function() {
$.get("http://localhost/test.php", function(data){
alert(data);
});
});
http://api.jquery.com/ready/
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With