| Conditions | 1 |
| Paths | 1 |
| Total Lines | 13 |
| Code Lines | 9 |
| Lines | 0 |
| Ratio | 0 % |
| 1 | <?php |
||
| 8 | public function up() |
||
| 9 | { |
||
| 10 | $wysiwyg = new Wysiwyg(); |
||
| 11 | $wysiwyg->class_name = 'app\widgets\TextareaWidget'; |
||
| 12 | $wysiwyg->name = 'Textarea'; |
||
| 13 | $wysiwyg->params = json_encode([ |
||
| 14 | 'htmlOptions' => [ |
||
| 15 | 'class' => 'form-control', |
||
| 16 | 'style' => 'height: 200px;' |
||
| 17 | ] |
||
| 18 | ]); |
||
| 19 | $wysiwyg->save(); |
||
| 20 | } |
||
| 21 | |||
| 28 |
You can fix this by adding a namespace to your class:
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.