I have recently upgraded from 8.1.5 to 8.2 through Nuget, and now when previewing nodes, I get:
Failed to load resource: the server responded with a status of 404 (Not Found)
Application?umb__rnd=637b8440e9a0c023130009e82bce987d:1 Uncaught ReferenceError: LazyLoad is not defined
at Application?umb__rnd=637b8440e9a0c023130009e82bce987d:1
If I run the project using IIS Express, or Local IIS, with the permissions on the project folder/IUSR and/or IIS_USERS set to "full access", this still makes no difference.
A note for testing this, when you make changes to the web.config file you may need to sign out of Umbraco and then back in for the preview feature to become available.
It appears that chrome will hard cache permanent redirects, so applying a fix in your rewrite rules might appear to do nothing at all. You might need to clear the cache by going to chrome://settings/clearBrowserData, and clearing 'Cached images and files'.
I'd hope this saves someone banging their head against a wall like me trying to figure out why it wasn't working.
Umbraco Preview Mode - Lazyload undefined
I have recently upgraded from 8.1.5 to 8.2 through Nuget, and now when previewing nodes, I get:
I have followed all steps from: https://our.umbraco.com/forum/umbraco-7/using-umbraco-7/53815-Uncaught-referenceError-LazyLoad-is-not-defined but had no luck.
Can anyone suggest anything else I can try to resolve this?
An update on my query, I have narrowed it down to if I remove/comment out the following in my web.config. The preview then works.
I need these redirects as there are 150+.
If I run the project using IIS Express, or Local IIS, with the permissions on the project folder/IUSR and/or IIS_USERS set to "full access", this still makes no difference.
Any help would be much apprenticed.
I would add a condition when the URL starts with /umbraco to not run the redirect.
Hi!
We use something like this to about this issue for backoffice-requests:
Thanks so much Markus. This has resolved the problem.
My final code is:
Thank you so much for the solution you posted, Markus. This has solved our problem.
This is what I ended up with:
A note for testing this, when you make changes to the web.config file you may need to sign out of Umbraco and then back in for the preview feature to become available.
Another note for testing this:
It appears that chrome will hard cache permanent redirects, so applying a fix in your rewrite rules might appear to do nothing at all. You might need to clear the cache by going to chrome://settings/clearBrowserData, and clearing 'Cached images and files'.
I'd hope this saves someone banging their head against a wall like me trying to figure out why it wasn't working.
For reference: https://stackoverflow.com/a/35093587
is working on a reply...