Items Listing & Each Item Details with different layout for Dynamic Module Item
Hi,
I created "Staff" dynamic module and wants to develop custom listing and details widget.
According to the video, www.youtube.com/watch, we can achieve custom listing and details widget using mvc.
However, I want different template layout for listing and details. In the example, they both show on the same template with same layout.
I want to add and show other custom widgets to listing view but I do not want to add and show other custom widgets for details view.
Please kindly advice how can I achieve what I want. Thanks a lot :)
I managed to implement the listing and details widgets using ASP.NET web forms user controls (.ascx)
I created separate widget for listing and details page. Listing widget is placed in listing page named "teaching staff" with it's own layout and other widgets. Details widget is placed in details page named "detail" with it's won layout and other widgets as well. Details page is child page of listing page.
Now everything is working as follows,
Listing, /teaching-staff/
Details, /teaching-staff/detail/peter-tan
However, I do not want "/detail/" part in the details URL. I want details url to be like "/teaching-staff/peter-tan"
Please kindly advice if there is a way to achieve this.
Sorry for my bad explanation if it's not easy to comprehend.
Thanks in advance.
Hello Zarni,
It all depends on your custom implementation. If your details widget is designed to display items in single view only you can place both list and detail widgets on the same page. Using this approach both views will be displayed on a single page.
You can also check and the following blog post which might be helpful.
Custom URL Formats for Sitefinity Content Modules
Other possible approach is to use URL rewrite. You can find more information from the following article:
Using URL Rewrite for SEO
Regards,
Kaloyan
Telerik
I just ran into the same scenario....Just wanted to give others a heads up about "Using URL Rewrite for SEO".
Just an FYI. Outbound rules withOUT some additional filters (i.e. filterByTags="A"), made the back office...specifically "Pages" section unusable.
Here are the rewrite rules that worked for me:
<rewrite>
<outboundRules>
<rule name="Menu Detail" stopProcessing="true">
<match filterByTags="A" pattern="(.*)/menu-detail/(.*)" />
<action type="Rewrite" value="R:1/R:2" />
</rule>
</outboundRules>
</rewrite>