slavkovrn/yii2-ion-rangeslider Yii2 Ion Range Slider widget uses Ion.RangeSlider plugin version 2.3.0 for jQuery with pjax support

IonRangeSlider widget for Yii2 Framework uses Ion.RangeSlider plugin version 2.3.0 for jQuery with pjax support

  1. Installation
  2. Usage

IonRangeSlider widget demo page

The extension uses Ion.RangeSlider plugin version 2.3.0 for jQuery https://github.com/IonDen and makes user interface for changing min,max values of any range with pjax support

IonRangeSlider widget

Installation

The preferred way to install this extension is through composer.

Either run:

composer require slavkovrn/yii2-ion-rangeslider

or add

"slavkovrn/yii2-ion-rangeslider": "*"

to the require section of your composer.json file.

Usage

Set link to extension in your view:

<?php
use slavkovrn\ionrangeslider\IonRangeSliderWidget;
use yii\widgets\ActiveForm;
use yii\helpers\Html;
?>
    <?php $form = ActiveForm::begin(); ?>

    <?= $form->field($model, 'username')->widget(IonRangeSliderWidget::class,[
	'min' => 0,
	'max' => 10,
	'from' => 2,
	'to' => 6,
    ]) ?>

    <?= $form->field($model, 'email')->widget(IonRangeSliderWidget::class,[
	'min' => 0,
	'max' => 10,
	'from' => 4,
	'to' => 8,
    ]) ?>

    <div class="form-group">
        <?= Html::submitButton('Save', ['class' => 'btn btn-success']) ?>
    </div>

    <?php ActiveForm::end(); ?>

write comments to admin

1 0
1 follower
1 290 downloads
Yii Version: 2.0
License: BSD-3-Clause
Category: User Interface
Developed by: Viacheslav Kolesnikov
Created on: Dec 8, 2019
Last updated: (not set)
Packagist Profile
Github Repository

Related Extensions