Some students must have encountered such a problem:
When the pop-up window is opened by the layer plugin, the popup cannot be closed after the form is submitted by jquery Ajax, or the parent page is not refreshed after the popup window is closed. How to solve the problem.
come on, guys, watch it together. Solution:
function SubmitForm () {
//Gets the value of the form item (slightly)
//submits the form data
$.ajax ({
URL: "Slightly",
type: "POST",
data: slightly,
dataType: "Text",
success:function (data) {
//Load Refresh parent class page and close popup
window.parent.location.reload ();
Parent.layer.closeAll (' iframe ');
},
error:function (XHR) {
alert (xhr.status)
}
);
};
If the above content is inappropriate, hope that the students of the great God. Thank you.
Copyright NOTICE: This article for Bo Master original, if reproduced please indicate the source.