Premium forums

Loading TabStrip content with AJAX

  • Kyle
    Kyle avatar

    31 May 2012 (Link to this post)

    It appears that the loading of content into the tabstrip divs is sensitive to any whitespace between the <div></div> tags.

    So in the example below html-content-snippet.html will not load in either div (in fact it appears the xhr call is never fired).

    Perhaps this is by design but it took me a bit to figure this nuance out.

    <div id="tabstrip">
        <ul>
            <li>First Tab</li>
            <li>Second Tab</li>
        </ul>
        <div> </div>
        <div>
        </div>
     </div>
    $(document).ready(function(){
        $("#tabstrip").kendoTabStrip({
            contentUrls: ["html-content-snippet.html", "html-content-snippet.html"]
        });
     });
  • Answered Kamen Bundev
    Kamen Bundev avatar

    01 Jun 2012 (Link to this post)

    Hello,

    Yes, this is by design - TabStrip is automatically trying to guess if Ajax loading is required. Actually the DIVs are not required at all - you can init your TabStrip from an UL element only. I went ahead and updated the documentation about it, it will be live soon.

    All the best,
    Kamen Bundev
    the Telerik team
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!

Read FAQ or see Kendo UI in action!

Launch Demos