oxy-coach / yii2-slug-generator-widget
Slug generating widget working with yii2 seo behavior
Installs: 48
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 0
Forks: 0
Open Issues: 0
pkg:composer/oxy-coach/yii2-slug-generator-widget
Requires
- php: >=7.0
- oxy-coach/yii2-seo-behavior: *
This package is not auto-updated.
Last update: 2025-10-12 11:37:06 UTC
README
Slug generating widget working with SeoBehavior for creating slug string on-fly using js.
Installation via Composer
Run the following command
$ composer require oxy-coach/yii2-slug-generator-widget "*"
or add
$ "oxy-coach/yii2-slug-generator-widget": "*"
to the require section of your composer.json file.
Configuring
Add action in the controller, for example:
use oxycoach\slugwidget\SlugGeneratorAction; \\ ... public function actions() { return [ 'slug-generate' => [ 'class' => SlugGeneratorAction::class, ], ]; }
Usage
use oxycoach\slugwidget\SlugGeneratorWidget; \\ ... <?= SlugGeneratorWidget::widget([ 'form' => $form, 'model' => $model, 'slugGenerationAction' => ['slug-generate'] ]); ?>
Configure slugGenerationAction property for different slug generating url route