Problem with yii\jui\Tabs

Hi guys,

I have a big problem with Yii Tabs. I have few tabs with forms. When I fill, for example, first tab and switch to second, all data I have entered in first tab is lost. How can I prevent this?

This is my tab code:





<?php


use yii\jui\Tabs;


?>

<div>

    <?php

    $rfp_id = $model->ProjectMainId;

    echo Tabs::widget(

        [


            'id' => 'tabs',

            'class'=> 'nav-tabs-custom',

            'items'=>[

                ['label'=>'General','url' => ['sponsor/rfp/general?id='.$rfp_id.'']],

                ['label'=>'Protocol  ','url'=>['sponsor/rfp/protocol?id='.$rfp_id.'']],

                ['label'=>'Countries  ','url'=>['sponsor/rfp/countries?id='.$rfp_id.'']],

                ['label'=>'Services  ','url'=>['sponsor/rfp/service']],

                ['label'=>'Timeline  ','url'=>['sponsor/rfp/timeline']],

                ['label'=>'Resources  ','url'=>['sponsor/rfp/resource']],

                ['label'=>'Documents  ','url'=>['sponsor/rfp/document']],

                ['label'=>'RFP Members  ','url'=>['sponsor/rfp/members']],

            ],

            'options' => ['tag' => 'div'],

            'itemOptions' => ['tag' => 'div'],

            'headerOptions' => ['class' => 'my-class'],

            'clientOptions' => ['collapsible' => false],

        ]

    );

    ?>


</div>



I soleved a problem. Instead of URL I put CONTENT and write code like this:





$timelineContent = $this->renderAjax('timeline', array('timelines'=>RfpController::getTimelines()));


echo Tabs::widget(

        [


            'id' => 'tabs',

            'class'=> 'nav-tabs-custom',

            'items'=>[

                ['label'=>'Timeline  ','content'=>$timelineContent],

            ],

            'options' => ['tag' => 'div'],

            'itemOptions' => ['tag' => 'div'],

            'headerOptions' => ['class' => 'my-class'],

            'clientOptions' => ['collapsible' => false],

        ]

    );




Now remembers all form content. Maybe this helps to somebody.