Use the following procedure to configure the URL format for modules that have more than one content type. For example, Blogs module that has Bogs and Blog posts content types.
Because the Blogs and the Blog posts have different URL format – the URL of the posts includes the URL of the blog, you cannot use the above procedure and change only the parameter of the data provider. To change the format of modules with multiple content types, you must create a custom provider and override some of the methods.
The following procedure removes the name of the blog from the URL of the blog post. After completing the procedure, you can further change the URL format using the advanced settings in the backend. For more information, see Manage the URL format through the advanced settings below.
Perform the following:
Use the following code sample:
To use the newly created data provider, you must register it. You can do this either by replacing the default provider, or by registering it as a new provider:
NOTE: If you have Sitefinity CMS Multisite you may have more than one provider. In this case, you can choose for which provider to apply the desired behavior, or you can apply it to all by replacing them with the custom one.
Once you register the new provider, all newly created posts have the new URL format - without the name of the blog. To change the URL for previously created posts, you need to republish all posts. You can do this manually or by using the following code sample:
Once you have created and registered your provider, you can manage its parameters through the Advanced settings.
Back To Top
To submit feedback, please update your cookie settings and allow the usage of Functional cookies.
Your feedback about this content is important
Copyright © 2022 Progress Software Corporation and/or its subsidiaries or affiliates.
All Rights Reserved.
Progress, Telerik, Ipswitch, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks for appropriate markings.
Powered by Progress Sitefinity