You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am creating a scheduled job in optimizely cms 12, that should expire a page (based om some parameters) and also move the page.
After that I wish to create a custom redirect to the old parent.
Having some issues with this.
It seems like NotFound has a Moved event hooked up that creates Redirects even on expired pages.
When I use IRedirectService and AddOrUpdate method, it works, but I think the move-event (e g MovedContentRegistratorBackgroundService ) is lagging and overwrites the redirect I am creating.
Is there a way around this?
Finding pages (with conditions)
Iterate; Set page as expired, move to specifik page
Perhaps add logic in ContentUrlHistoryEvents to also take into consideration if the moved page is published or not.
I guess I could use my own implementation of ContentUrlHistoryEvents. :)
I am creating a scheduled job in optimizely cms 12, that should expire a page (based om some parameters) and also move the page.
After that I wish to create a custom redirect to the old parent.
Having some issues with this.
It seems like NotFound has a Moved event hooked up that creates Redirects even on expired pages.
When I use IRedirectService and AddOrUpdate method, it works, but I think the move-event (e g MovedContentRegistratorBackgroundService ) is lagging and overwrites the redirect I am creating.
Is there a way around this?
_redirectsService.DeleteByOldUrl(oldPageUrl); _redirectsService.AddOrUpdate(new CustomRedirect(oldPageUrl, parentPageUrl, true, RedirectType.Temporary));
The text was updated successfully, but these errors were encountered: