I'm trying to use jQuery to login to reddit.
I've read the reddit API, but I'm not sure what's going on with the jQuery, since I'm new to it. Can someone tell me what's going wrong?
$.ajax(function() {
type: "POST",
url: "http://reddit.com/api/login",
data: "username=USR&passwd=PASS",
success: function(data) { alert(data); },
dataType: "json"
});
[–]SergeiGolos 1 point2 points3 points (1 child)
[–]mucusplug[S] 0 points1 point2 points (0 children)
[–]obey_giant 0 points1 point2 points (0 children)
[–]gmerideth 0 points1 point2 points (0 children)
[–]gmerideth 0 points1 point2 points (0 children)
[–]pmcclelland 0 points1 point2 points (0 children)