1/ you create new Managed Path Prefix: your_prefix
2/ create your site
using (SPSite site = new SPSite("http://abc.com"))
{
//create your_prefix
site.WebApplication.Prefixes.Add("your_prefix", SPPrefixType.WildcardInclusion);
//create new site with your_prefix
site.WebApplication.Sites.Add("http://abc.com/your_prefix/newsite", ... ) ;
}
No comments:
Post a Comment