SharePoint 2013 Hosting – :: Developing a Site Collection in 2010 Mode in SharePoint 2013

These days I got phoned up by a buddy who asked how on earth he could programmatically produce a web site collection in 2010 mode in SharePoint 2013. Why he wanted to do this I’m not confident, and it is not the point of this post

ahp banner sharepoint-01It’s truly pretty uncomplicated if you appear at the documentation of some of the SPSiteCollection.Add() strategies which take an int as a compabilityLevel parameter. Passing in 14 in this parameter will make certain you get the 2010 appear and really feel. For reference the SPSite.SelfServiceCreateSite() technique has equivalent overloads.

SPWebApplication webApp = new SPSite(<a href="http://host/">http://host</a>).WebApplication;
SPSiteCollection siteCollections = webApp.Sites;
uint lcid = 1033;
int compatLevel = 14;
string webTemplate = "STS#0";
SPSite newSiteCollection = siteCollections.Add("sites/test", "Title", "Description", 1033, compatLevel, webTemplate,
 "DOMAIN\\User", "Name", "Email_Address", "DOMAIN\\User", "Name", "Email_Address");

If you want to do it I PowerShell you can use the following command:

New-SPSite -Url http://host/sites/test -OwnerAlias "DOMAIN\User"

And via Central Admin:

3lkdnvlrBest Recommended SharePoint 2013 Hosting is Perfect, suitable hosting plan for a starter in SharePoint. ASPHostPortal  the leading provider of Windows hosting and affordable SharePoint Hosting. ASPHostPortal proudly working to help grow the backbone of the Internet, the millions of individuals, families, micro-businesses, small business, and fledgling online businesses. ASPHostPortal has ability to support the latest Microsoft and ASP.NET technology, such as: WebMatrix, WebDeploy, Visual Studio 2015, .NET 5/ASP.NET 4.5.2, ASP.NET MVC 6.0/5.2, Silverlight 6 and Visual Studio Lightswitch, ASPHostPortal guarantees the highest quality product, top security, and unshakeable reliability, carefully chose high-quality servers, networking, and infrastructure equipment to ensure the utmost reliability