infinitydesign / yii2-jalali-datepicker
Bootstrap 4 Date Picker for Yii2 Extension
This package's canonical repository appears to be gone and the package has been frozen as a result. Email us for help if needed.
Package info
github.com/infinitydesign/yii2-jalali-datepicker
Language:JavaScript
Type:yii2-extension
pkg:composer/infinitydesign/yii2-jalali-datepicker
v1.2.1
2019-11-25 14:05 UTC
Requires
- yiisoft/yii2: *
Requires (Dev)
None
Suggests
None
Provides
None
Conflicts
None
Replaces
None
README
Jalali Date Picker for Bootstrap Yii2 Extension
Installation
The preferred way to install this extension is through composer.
Either run
php composer.phar require --prefer-dist infinitydesign/yii2-jalali-datepicker "*"
or add
"infinitydesign/yii2-jalali-datepicker": "*"
to the require section of your composer.json file.
Usage
Once the extension is installed, simply use it in your code by following code :
<?php use infinitydesign\jalaliDatePicker\jalaliDatePicker; echo $form->field( $model, 'date' ) ->widget( jalaliDatePicker::className(), [ 'options' => array( 'format' => 'yyyy/mm/dd', 'viewformat' => 'yyyy/mm/dd', 'placement' => 'right', 'todayBtn'=> 'linked', ), 'htmlOptions' => [ 'id' => 'date', 'class' => 'form-control', 'placeholder' => '1396/05/05', 'readonly' => 'readonly' ] ]); ?>