+1-888-365-2779
Try Now
More in this section

Forums / Designing with Sitefinity / Tab Strip selected tab

Tab Strip selected tab

3 posts, 0 answered
  1. Smitha
    Smitha avatar
    22 posts
    Registered:
    29 Oct 2008
    23 Dec 2008
    Link to this post
    Hi!

    I am usign the Tab strip as my menu control. I have set the cssclass to my class in proeprties and it works fine. But I would like to change the background of the control when it is on selected page.

    Can you help ASAP please as we are at the end of our project.

    Thanks! for all your help.

    Regards,
    Smitha.
  2. Pepi
    Pepi avatar
    981 posts
    Registered:
    08 Dec 2016
    23 Dec 2008
    Link to this post
    Hello Smitha,

    A possible solution is to modify the code of the SiteTabstrip user control (~/Sitefinity/UserControls/Navigation35/SiteTabstrip.ascx.cs). You could create a new CSS class (for example selectedTab) that will apply when the tab is selected:

    .ascx
    <style type="text/css"
    .selectedTab  
        color: Red !important; 
        } 
    </style> 
     
    <div> 
        <telerik:RadTabStrip ID="RadTabstrip1" runat="server" EnableViewState="false"
        </telerik:RadTabStrip> 
    </div> 

    .ascx.cs
    RadTab item = this.RadTabstrip1.FindTabByUrl(this.ResolveUrl(node2.Url)); 
                    if (item != null
                    { 
                        // here you can set the style for the top-level item    
                        item.Selected = true
                        item.CssClass = "selectedTab"
                    } 

    Hope this helps.

    Sincerely yours,
    Pepi
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  3. Smitha
    Smitha avatar
    22 posts
    Registered:
    29 Oct 2008
    23 Dec 2008
    Link to this post
    Thanks! This was fast.

    We were able to make our changes. Will let you know if we need anything more.

    Regards,
    Smitha.
Register for webinar
3 posts, 0 answered