Close

How to change Tabs order?

maxkomarov
12 years ago
#589 Quote
Avatar
  • 6
It's possible?
I need display default Tabs (description, specification and reviews) after custom Tabs.
Thank you
Support
12 years ago
#593 Quote
Avatar
  • Moderator
  • 1044
maxkomarov wrote:
It's possible?
I need display default Tabs (description, specification and reviews) after custom Tabs.
Thank you


Hi maxkomarov,

This is not possible out of the box.
To do this you need to modify the Razor view for the tabs a little bit.
The easiest way to do this is when Ajax is not enabled.
Open Views\ProductTab\_ProductTabs.cshtml file in Visual Studio or some text editor. Cut the code from line 203-207 (see the code below) and paste it on line 183 just after the opening <li> tag and before the product description tab check.

@foreach (var tab in Model.Tabs)
{
  divs.Add(new KeyValuePair<string, string>("tabs-" + tab.Id.ToString(), tab.Description));
<li><a href="#[email protected]">@tab.DisplayName</a> </li>                
}


We assume you are using version 2.5 of the Tabs otherwise the line numbers will be a little bit different.
Please let us know if you have any problems doing this!

Hope this helps!
Nop-Templates Support Team
maxkomarov
12 years ago
#596 Quote
Avatar
  • 6
Support wrote:
The easiest way to do this is when Ajax is not enabled.
Open Views\ProductTab\_ProductTabs.cshtml file in Visual Studio or some text editor. Cut the code from line 203-207 (see the code below) and paste it on line 183 just after the opening <li> tag and before the product description tab check.

@foreach (var tab in Model.Tabs)
{
  divs.Add(new KeyValuePair<string, string>("tabs-" + tab.Id.ToString(), tab.Description));
<li><a href="#[email protected]">@tab.DisplayName</a> </li>                
}



It's work fine.
Thank you