This is a migrated thread and some comments may be shown as answers.

[Solved] custom tab css

1 Answer 120 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Greg Rated
Top achievements
Rank 1
Greg Rated asked on 02 Oct 2009, 04:08 AM
I have a couple of tab objects on a page and would like to have one of them render with a different css style. Can I override the default jquery style?

<% Html.jQuery().Tab()
        .Name("customtab")
        .HtmlAttributes(new { @class="is this right?" } )
        .SpinnerText("Loading")
        .CacheAjaxResponse(true)
        .Items(parent =>
                      {

Thanks,

Greg

1 Answer, 1 is accepted

Sort by
0
Alex Gyoshev
Telerik team
answered on 06 Oct 2009, 08:01 AM
Hi Greg,

This can be achieved through HtmlAttributes, indeed, yet you are setting them on the TabStrip. If you want to set the styles on a per-tab basis, you should do it like this:

.Items(parent =>
              {
                  parent.Add()
                      .Text("Nunc tincidunt")
                      .HtmlAttributes(new { @class = "test" });
              })


All the best,
Alex
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
General Discussions
Asked by
Greg Rated
Top achievements
Rank 1
Answers by
Alex Gyoshev
Telerik team
Share this question
or