jidniilman / yii-slug-input
Generate auto slug text from any input using model input or just Html id attribute. Forked from wardany/yii-slug-input
Package info
github.com/jidnilussa/yii-slug-input
Type:yii2-extension
pkg:composer/jidniilman/yii-slug-input
dev-master
2021-11-04 05:34 UTC
Requires
- jidniilman/yii-slug-input: dev-master
- yiisoft/yii2: *
This package is not auto-updated.
Last update: 2022-01-14 04:43:20 UTC
README
Generate auto slug text from any input using model input or just Html id attribute
Installation
The preferred way to install this extension is through composer.
Either run
php composer.phar require --prefer-dist wardany/yii-slug-input:dev-master
or add
"wardany/yii-slug-input": "dev-master"
to the require section of your composer.json file.
Usage
Once the extension is installed, simply use it in your code by :
<?= $form->field($model, 'slug')->widget(Slugify::className(),['source_attribute'=>'title', 'separator'=>'_', 'disable'=> true]) ?>```