Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
Hi Richard.I noticed that in the backend the page is not deleted (nice!), however in the frontend the page is gone (page not found error). The page only returns in the frontend when I republish it. Maybe some cache problem?Thanks.FernandoUmbraco 4.5.2 for .Net 3.5 with MySQL 5.1
I think it gets unpublished before the item gets deleted, not much I can do about that :-(.For the next version I will remove the delete button based on the property since I know a nice way to cache things now.
Since the document gets unpublished you could just re-publish again after preventing it from being deleted. So you could change your method to something like:
private static bool CheckDisabledForDelete(Document document)
const string DISABLEDELETEALIAS = "umbracoDisableDelete";
bool cancel = document.getProperty(DISABLEDELETEALIAS) != null && document.getProperty(DISABLEDELETEALIAS).Value.Equals(1);
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted