About loading data with ajax

2 posts, 0 answers
  1. JIA DONG
    JIA DONG avatar
    1 posts
    Member since:
    Aug 2011

    Posted 14 Sep 2011 Link to this post

    first, this's a great thing. 
    I have seen the API and demo. Then for a Test,for the TabStrip.

    Loading content with AJAX ,this does not work!


    I view the API in kendoui.com ,it doesn't work too.

    what's the matter?

    I Want to add a new Tab , this tab loading content with ajax.

    how can I write the code? the API doesn't have a prompt, it doesn't have any description about the params.

    this is my code, not work too.

    var tabStrip=$("#tabstrip").kendoTabStrip().data("kendoTabStrip");
    tabStrip.insertAfter([{text:"New Tab3",content:[null,"http://www.danamy.cn/index.html"]},{text:"New Tab4"}],tabStrip.tabGroup.children("li:last"));

    I'm Chinese , English is so so. - -.
  2. Kamen Bundev
    Admin
    Kamen Bundev avatar
    1532 posts

    Posted 15 Sep 2011 Link to this post

    Hello Jia Dong,

    Unfortunately adding items with Ajax loaded content is not possible through the current API. We patched it up for the next beta, until then you can use the attached minified TabStrip source as a workaround (or initialize all tabs from the start), like this:
    tabStrip.append(
        [{
            text: "New Tab3",
            contentUrl: "ajax/ajaxContent1.html"
        },
        {
            text: "New Tab4",
            content: "Test"
        }],
        tabStrip.tabGroup
    );


    Kind regards,
    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!
Back to Top