我想調試一個內置在Flash中的聯繫表單,但我不知道如何去調試這個。從ActionScript中,我可以判斷它應該將結果發佈到/assets/files/functions.php。問題是,當我填寫字段並點擊'發送'(應該觸發這個)時,沒有任何反應,我不知道它是PHP問題還是閃存問題。ActionScript - 聯繫表單不工作
有沒有關於如何調試的想法?
該網站可能是found here,點擊「連接」後點擊「發送查詢」即可看到該表單。
的代碼可以在下面看到:
lvOut = new LoadVars(); //create lv object
lvIn = new LoadVars(); //create lv object
lvIn.onLoad = function (success) {
if(success){
gotoAndPlay("success");
}else{
gotoAndPlay("failure");
}
}
function submit() {
if ((inputName.text != "") && (inputAddress.text != "") && (inputCity.text != "") && (inputState.text != "")
&& (inputCountry.text != "") && (inputTelephone.text != "") && (inputEmail.text != "")) {
lvOut.input_name = inputName.text;
lvOut.input_address = inputAddress.text;
lvOut.input_city = inputCity.text;
lvOut.input_state = inputState.text;
lvOut.input_zip = inputZip.text;
lvOut.input_country = inputCountry.text;
lvOut.input_telephone = inputTelephone.text;
lvOut.input_email = inputEmail.text;
lvOut.input_bedrooms = inputBedrooms.text;
lvOut.input_realtor = inputRealtor.text;
lvOut.input_comments = inputComments.text;
if (realtorYes) {
lvOut.input_hasRealtor = "yes";
} else if (realtorNo) {
lvOut.input_hasRealtor = "no";
} else {
lvOut.input_hasRealtor = "no answer";
}
//send vars to functions page and load in result
lvOut.sendAndLoad("assets/files/functions.php", lvIn, "POST");
}
}
btnSend.addEventListener("click", submit);
請幫我出盡可能多的! :-)
如果你發佈了一些代碼,我們也許能夠提供幫助。 –
好點。現在添加代碼..很抱歉! –