當我使用此代碼時,我只設法檢索recaptcha_response_field。如果我刪除了recaptcha_response_field,我將檢索recaptcha_challenge_field。但是,我無法同時找回兩者。 我只設法發送1個數據。jquery.ajax多個數據檢索
challengeField = $("#recaptcha_challenge_field").val();
responseField = $("#recaptcha_response_field").val();
var html = $.ajax(
{
global: false,
type: "POST",
async: false,
dataType: "html",
data: "recaptcha_response_field=" + responseField + "&recaptcha_challenge_field=" + challengeField,
url: "../ajax.recaptcha.php"
}).responseText;
if(html == "success")
{
$("#captchaStatus").html("Success. Submitting form.");
return true;
}
else
{
$("#captchaStatus").html("Your captcha is incorrect. Please try again");
Recaptcha.reload();
return false;
}
再次,只有一個工作 – 2010-03-23 17:30:21
檢查擴大答案 – jitter 2010-03-23 17:58:20
是的,這正是我的意思。我不知道爲什麼... 我使用joomla如果可以幫助。 服務器日誌中沒有任何相關內容。 謝謝 – 2010-03-23 18:58:52