Yii 1.1: bootslider

BootSlider - Is a widget that be can used as bootstrap widget
19 followers

BootSlider use Twitter's Bootstrap extension together with Yii. There are sevral Yii-widgets that allow you to easily use Bootstrap with Yii.BootSlider is a widget that use Carousel in Twitter's Bootstrap and extended from CListView so using CArrayDataProvider or CActiveDataProvider we can create image slider

Download

download

GitHub

Requirements

yii-bootstrap-0.9.9.r119

Update

  • added auto slider

    'slide'=>array(true,2000),//to slide after 2seconds

    'slide'=>array(true),// default after 6seconds

    /*

    no need to use 'slide' if no automatic sliding is needed

    --- or -----

    'slide'=>array(false),

    */

Usage

setup bootstrap extension in your yii app by referring http://www.yiiframework.com/extension/bootstrap then add this widget in your "protected/extensions/bootstrap/widgets"

then use following code set pagination always false

//$rawData is array 
$listDataProvider=new CArrayDataProvider($rawData, array(
 
    'pagination'=>false,//always false
));
 
<?php $this->widget('bootstrap.widgets.BootSlider',
    array('itemView'=>'_list',//_lsit is the php file to render
        'id'=>'Mycarouse1',//id of Carousel
              'slide'=>array(true,2000),//to slide after 2seconds   
        'dataProvider'=>$listDataProvider,
        'coloumCount'=>4,//no of items to shown in slider
));?>
 
//_list.php
<style>
a #image{
height:150px;
}
</style>
 
<div class="thumbnail span2">
 
        <img id="image" src="<?php echo Yii::app()->baseUrl.'/images/'.$data['image']; ?>" alt="">
 
</div>

Resources

support@nintriva.com * Nintriva

Total 6 comments

#17571 report it
francis ja at 2014/07/03 04:02pm
fixed

fixed, it will work now

#15741 report it
Selvakumar at 2013/12/11 02:45am
Bootstrap and its behaviors do not have a method or closure named "enableTransitions"

Bootstrap and its behaviors do not have a method or closure named "enableTransitions". I am sure this is from all the changes that have been made to bootstrap since you last updated this extension. Any idea how to fix it?

#13386 report it
lake at 2013/05/27 04:44am
$rawData ???

where is the "$rawData" definition?

#12311 report it
pathman at 2013/03/13 05:02am
thanks

nice extensions

#9516 report it
MAHESH.E.U at 2012/08/20 01:34am
good one.

good one. working fine for me.

#8871 report it
deez at 2012/07/05 10:03am
error

Bootstrap and its behaviors do not have a method or closure named "enableTransitions". I am sure this is from all the changes that have been made to bootstrap since you last updated this extension. Any idea how to fix it?

Leave a comment

Please to leave your comment.

Create extension