mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-21 11:17:28 +08:00
#19654: 404 when click "unpublish" or "publish" in Blog Module.
--HG-- branch : 1.x extra : source : 54d46ec006b20bfa7559f32bd9b9d1df1b90b9d1
This commit is contained in:
@@ -223,7 +223,7 @@
|
||||
$(function () {
|
||||
var magicToken = $("input[name=__RequestVerificationToken]").first();
|
||||
if (!magicToken) { return; } // no sense in continuing if form POSTS will fail
|
||||
$("a[itemprop~=UnsafeUrl]").on("click", function () {
|
||||
$("a[itemprop~=UnsafeUrl]").on("click", function() {
|
||||
var _this = $(this);
|
||||
var hrefParts = _this.attr("href").split("?");
|
||||
var form = $("<form action=\"" + hrefParts[0] + "\" method=\"POST\" />");
|
||||
@@ -238,16 +238,16 @@
|
||||
}
|
||||
form.css({ "position": "absolute", "left": "-9999em" });
|
||||
$("body").append(form);
|
||||
_this.click(function () {
|
||||
if (_this.filter("[itemprop~='RemoveUrl']").length == 1) {
|
||||
if (!confirm(confirmRemoveMessage)) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
form.submit();
|
||||
return false;
|
||||
});
|
||||
if (_this.filter("[itemprop~='RemoveUrl']").length == 1) {
|
||||
if (!confirm(confirmRemoveMessage)) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
form.submit();
|
||||
return false;
|
||||
|
||||
});
|
||||
});
|
||||
})(jQuery);
|
||||
|
Reference in New Issue
Block a user