Achieving a site-specific URL pattern for a multisite environment

Sitecore provides the LinkProvider class, which contains different properties to achieve different URL patterns such as adding a .aspx extension, location of language, language embedding, lowercase URLs, and so on. The LinkManager in Sitecore can contain multiple LinkProviders (multiple URL patterns), and any one LinkProvider can be set as the default. The URL configuration set in the default link provider will be applied to all the sites' URLs.

Consider a case where you are working on a multisite solution, and different websites need different URL patterns. One site is built with a single language, so its URLs will not contain language information; other multilingual sites may need ...

Get Sitecore Cookbook for Developers now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.