當按下提交按鈕文本不更新..甚至沒有加載框確實出現在IE ...在Firefox中一切都很好!jquery和IE問題!
$(".form_edit_review").live('submit', function(e){
e.preventDefault();
$submittingForm = $(this);
loading("Updating...");
postData = $submittingForm.serialize();
$.post('/review/update', postData, function(xml){
closeBoxy();
var success = $("success", xml).text();
var message = $("message", xml).text();
if (success == "false")
{
boxy_alert(message);
}
else
{
$submittingForm.hide().parents("div.resto_review_bg").find(".review_text").html($submittingForm.find("textarea").val()).show();
}
});
});
html代碼:
<form class="form_edit_review" id="formEditReview_<?php echo $row['review_id']?>" style="display: none;">
<textarea name="content" style="border: 1px solid #C2C2C2; padding: 10px; width: 547px; height: 45px;"><?php echo $row['review'];?></textarea>
<input type="hidden" value="<?php echo $row['review_id']?>" name="id" />
<input type="hidden" value="<?php echo $row['resto_id']?>" name="restoid" />
<p style="margin-top: 5px;">
<input class="btn_comment btn_update" value="Update" type="submit" />
<input class="btn_comment btn_cancel" value="Cancel" type="button" />
</p>
</form>
你沒有顯示所有相關的代碼,你看到的錯誤,或告訴我們你已經嘗試過。使用Fiddler並查看POST是否成功。 – 2010-04-12 15:24:24