All Projects → MetalGuardian → Yii2 Fotorama Widget

MetalGuardian / Yii2 Fotorama Widget

Licence: mit
Fotorama image gallery widget for yii2

Projects that are alternatives of or similar to Yii2 Fotorama Widget

yii2-switch-widget
Bootstrap Switch Widget for Yii2
Stars: ✭ 17 (-5.56%)
Mutual labels:  widget, yii2
yii2-highcharts-widget
HighCharts Js Widget for Yii2
Stars: ✭ 40 (+122.22%)
Mutual labels:  widget, yii2
yii2-content-tools
ContentTools editor implementation for Yii 2
Stars: ✭ 79 (+338.89%)
Mutual labels:  widget, yii2
Yii2 Date Picker Widget
Bootstrap DatePicker Widget for Yii2
Stars: ✭ 128 (+611.11%)
Mutual labels:  yii2, widget
yii2-multi-select-widget
Bootstrap MultiSelect and MultiSelect Listbox widgets for Yii2
Stars: ✭ 45 (+150%)
Mutual labels:  widget, yii2
Yii2 Imperavi Widget
Imperavi Redactor widget for Yii 2
Stars: ✭ 250 (+1288.89%)
Mutual labels:  yii2, widget
yii2-widget-cropbox
This widget allows crop image before upload to server and send informations about crop in JSON format.
Stars: ✭ 90 (+400%)
Mutual labels:  widget, yii2
yii2-datetime-widgets
Datetime widgets for Yii2
Stars: ✭ 22 (+22.22%)
Mutual labels:  widget, yii2
yii2-time-down-counter
Widget for yii2, to start count down timer with a lot of options, This widget build dependence of timeDownCounter JS library
Stars: ✭ 15 (-16.67%)
Mutual labels:  widget, yii2
yii2-google-analytics
Google Analytics Universal tracking widget.
Stars: ✭ 14 (-22.22%)
Mutual labels:  widget, yii2
Yii2 Sortable Widgets
🍨 Rubaxa/Sortable for Yii2
Stars: ✭ 54 (+200%)
Mutual labels:  yii2, widget
yii2-notification-wrapper
Yii2-notification-wrapper module renders a message from session flash (with ajax, pjax support and etc.) through Growl, Noty, Toastr and more libraries
Stars: ✭ 78 (+333.33%)
Mutual labels:  widget, yii2
Yii2 Quill
Yii 2 implementation of Quill, modern WYSIWYG editor
Stars: ✭ 52 (+188.89%)
Mutual labels:  yii2, widget
yii2-grid-view-library
Highly enhanced GridView widget and grid components for Yii2
Stars: ✭ 57 (+216.67%)
Mutual labels:  widget, yii2
yii2-cookiemonster
Yii extension to manage cookie warning
Stars: ✭ 16 (-11.11%)
Mutual labels:  widget, yii2
yii2-number
A number format mask control and input for Yii2 Framework
Stars: ✭ 22 (+22.22%)
Mutual labels:  widget, yii2
Yii2 Fullcalendar
Widget for Yii Framework 2.0 to use FullCalendar
Stars: ✭ 5 (-72.22%)
Mutual labels:  yii2, widget
Stepper Touch
Stepper Touch for Android based on MaterialUp submission
Stars: ✭ 621 (+3350%)
Mutual labels:  widget
Circular Music Progressbar
Beautiful Circular Progress Bar with album art for android
Stars: ✭ 813 (+4416.67%)
Mutual labels:  widget
Yii2admin
通用的yii2后台,基于Yii2的advanced应用程序模板,整合RBAC、Menu、Config、Migration多语言、RESTfull等等...
Stars: ✭ 619 (+3338.89%)
Mutual labels:  yii2

DEPRECATED

Unfortunately, original Fotorama gallery is no longer maintained. You still can use this extension if fotorama fits your project. Check github thread for alternatives.

Fotorama Yii2 widget

This yii2 extension is a wrapper for the powerful jQuery gallery Fotorama.

Latest Stable Version Total Downloads Latest Unstable Version License

Scrutinizer Code Quality Code Coverage Build Status Code Climate

Installation

Install this extension using composer.

composer require metalguardian/yii2-fotorama-widget

You should have configured asset-packagist repository in your project's composer.json or installed fxp/composer-asset-plugin plugin. For more information see Yii2 bower/npm assets manual

Usage

First way:

    <?php 
    $fotorama = \metalguardian\fotorama\Fotorama::begin(
        [
            'options' => [
                'loop' => true,
                'hash' => true,
                'ratio' => 800/600,
            ],
            'spinner' => [
                'lines' => 20,
            ],
            'tagName' => 'span',
            'useHtmlData' => false,
            'htmlOptions' => [
                'class' => 'custom-class',
                'id' => 'custom-id',
            ],
        ]
    ); 
    ?>
        <img src="http://s.fotorama.io/1.jpg">    
        <img src="http://s.fotorama.io/2.jpg">
        <img src="http://s.fotorama.io/3.jpg">
        <img src="http://s.fotorama.io/4.jpg">
        <img src="http://s.fotorama.io/5.jpg">
    <?php \metalguardian\fotorama\Fotorama::end(); ?>

Second way:

    <?php 
    echo \metalguardian\fotorama\Fotorama::widget(
        [
            'items' => [
                ['img' => 'http://s.fotorama.io/1.jpg', 'id' => 'id-one',],
                ['img' => 'http://s.fotorama.io/2.jpg',],
                ['img' => 'http://s.fotorama.io/3.jpg',],
                ['img' => 'http://s.fotorama.io/4.jpg',],
            ],
            'options' => [
                'nav' => 'thumbs',
            ]
        ]
    ); 
    ?>

To use CDNJS put this before run widget, will be used current version:

    <?php \metalguardian\fotorama\Fotorama::$useCDN = true; ?>

Or select custom version:

    <?php \metalguardian\fotorama\Fotorama::$useCDN = '4.5.0'; ?>

To setup default Fotorama widget options to all galleries on page:

    <?php 
    \metalguardian\fotorama\Fotorama::setDefaults(
        [
            'nav' => 'thumbs',
            'spinner' => [
                'lines' => 20,
            ],
            'loop' => true,
            'hash' => true,
        ]
    );
    ?>

For complete documentation of Fotorama and all widget options please refer to the official Fotorama page

License

yii2-fotorama-widget is released under the MIT License. See the bundled LICENSE for details.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].