...

View Full Version : how to request a url with parameters



mak2cool
02-01-2011, 03:55 PM
i m trying to implement captcha in my site.i m using recaptcha.

To check the captcha

i need to request url like:
http://www.google.com/recaptcha/api/verify?privatekey="key"&remoteip="ip"&challenge="chal"&response="res"

and then i need to check response from url if it is true or false

i dont know how to request response from url

help plz

gusblake
02-01-2011, 04:20 PM
Are you talking about an AJAX request?



var req=XMLHttpRequest?new XMLHttpRequest():new ActiveXObject("Microsoft.XMLHTTP");
req.open("GET", url, false);

req.onreadystatechange=function() {
if(req.readyState==4) {
alert(req.responseText);
}
}

req.send(null);

mak2cool
02-01-2011, 05:02 PM
no, i think its some thing different


i will describe problem in detail
actually its a two step process

1st is displaying recaptcha
http://code.google.com/apis/recaptcha/docs/display.html
which i have done

2nd is verifying answer
http://code.google.com/apis/recaptcha/docs/verify.html
i m stuck here


i m new to java script....so plz try to explain things in lil detail.......

thanks



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum