开发者

jQuery/PHP Posting multiple values

开发者 https://www.devze.com 2023-02-07 13:14 出处:网络
I\'m using JQuery UI t开发者_高级运维o post multiple values in a dialog to a php script but I cannot seem to get them posted. I\'ve seem examples using forms but I\'m not using a form so they do not h

I'm using JQuery UI t开发者_高级运维o post multiple values in a dialog to a php script but I cannot seem to get them posted. I've seem examples using forms but I'm not using a form so they do not help either, really could do with some advice please


You have a syntax error: missing property id.

     $.post("addReading.php", {
                METER_READ: $(this).val(),
                DATE_TAKEN: $(this).val(),
                NOTES: NOTES.val() // I added NOTES:
            }, function (data) {

and your last }); are too much (but that might be a copy/paste error).

Other than that I do not see why it does not work, but I cannot test it without a test case.

You should go on learning how to deal with firebug, though, because I'm sure it would have said you that the property id is missing (firebug is very good at detecting syntax errors, no need for humans in that case ;-) )

0

精彩评论

暂无评论...
验证码 换一张
取 消