For the past week, I was trying to figure out an issue related to the Experience Editor in Sitecore as it was rendering JSON as content. I started to search an existing solution to see if someone ran into it before, and yes! Obviously, a lot of developers saw this before and I found a lot of solutions. Unfortunately non of them worked for me. There is no one reason for this issue, it could be anything. As this was an upgrade project, I decided to install a clean Sitecore instance from the exact same version and revision and start comparing files. I started with replacing all core Sitecore DLLs from the clean instance into the upgraded instance. Unluckily, this idea did not fix the issue. At a glance, I saw this what called webedit.css and I thought this might be the issue. I compared both files from both instances and there were a lot of differences. I decided to replace this file with the one from the clean instance, cleared my cache, tested the Experience Editor, problem solved. I suspect the old webedit.css found its way to the new instance through the migration process, maybe...
Steps to reproduce:
- Navigate to your Sitecore client.
- Pick an item with its Presentation Details set so you can view it in your Experience Editor.
- Go to Publish > Under Publish section choose Experience Editor. You will see something like the screenshot below:
Here are some solutions I came across:
- Ensure that Sitecore.MvcExperienceEditor.config file is enabled.
- Ensure that webedit.css file is getting loaded and accessible.
- Ensure your HTML is not causing any issue and properly closing your tags.
- Verify that you are not getting any jQuery conflict related errors.
My Resolution:
Note: Remember, this was an upgrade project and this resolution worked for me specifically for this project. It may help you out one day :)
- Install a clean Sitecore instance with the same exact version and revision.
- Replace your webedit.css file from your newly installed clean Sitecore instance, Usually located in C:\inetpub\wwwroot\Your Website Name\Website.
- Issue should be resolved.
Until next time!