我想發送POST數據到我的php文件notify.php。爲此,我正在使用:無法發送POST請求與jQuery和AJAX
$.post("notify.php", { phone : phone_number });
phone_number是HTML中的輸入名稱。但郵政沒有發送。我用Firebug firefox插件來檢查AJAX錯誤並得到:
TypeError: 'stepUp' called on an object that does not implement interface HTMLInputElement.
...i+"["+k+"]",n)}):f(i,o)}function f(i,o){o=c.isFunction(o)?o():o;e[e.length]=enco...
什麼是錯?
'{ 「手機」:$( '#PHONE_NUMBER')值()}' – Anthony 2014-10-11 04:15:30
我不認爲誤差是相關到'$ .post()'。 – Barmar 2014-10-11 04:15:38
@Anthony我認爲你的意思是'.val()'。但他可以完成'phone_number = $('#phone_number')。val()'。 – Barmar 2014-10-11 04:17:07