0

In our SharePoint 2013 environment, we had mounted the SharePoint 2010 Content Databases and the sites are running in 2010 mode. As the sites are gradually being upgraded to 2013 Look and Feel, we are working on the custom code upgrade.

My basic understanding was that a site running in 2010 mode in SharePoint 2013 won't be able to work with solutions deployed with "Compatibility Level 15".

But, recently we came across a scenario where we have a site running in 2010 mode scheduled for an upgrade and we had both the 2010 code (Compatibility Level 14) and the upgraded code (Compatibility Level 15) deployed in the farm. We noticed that, for the site, the changes made in the ".ascx" files in the "14 Hive" were not reflected on the site whereas when the same change was applied to the files in "15 Hive", The changes were visible.

Please explain why this would happen?

2

here are some good information.

It is important to note that Compatibility Level impacts only files deployed to the Templates folder in the 14/15 Root folder. That is: Features, Layouts-files, Images, ControlTemplates, etc. This means that files outside of this folder (e.g. a WCF Service deployed to the ISAPI folder) will be deployed to the 15/ISAPI no matter what level is set in the manifest or PowerShell. Files such as Assemblies in GAC/Bin and certain resource files will also be deployed to the same location regardless of the Compatibility Level.

Also

  • If you want to run with both 2010 and 2013 mode, and want to share features and layout files, then deploy to both (All or “14,15”).
    • If you want to differentiate the files and features that are used in 2010 and 2013 mode, then the solutions should be split into two or three solutions: One solution (“Xxx – SP2010”), which contains the files and features to be deployed to the 14 folder for 2010 mode. including code-behind (for things like feature activation and Application pages), but excluding shared assemblies and files.
    • One solution (“Xxx – SP2013”), which contains the files and features to be deployed to the 15 folder for 2013 mode, including code-behind (for things like feature activation and Application pages), but excluding shared assemblies and files.
    • One solution (“Xxx – Common”), which contains shared files (e.g. common assemblies or web services). This solution would also include all WebApplication scoped features such as bin-deployed assemblies and assemblies with SafeControl entries.

Check this Article for more understanding about it.

Running SharePoint 2013 in 2010 mode and solution “CompatibilityLevel”

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.