Answer the question
In order to leave comments, you need to log in
How to finalize the formation of CNC?
Hello. I use the zelenin/yii2-slug-behavior extension to form the CNC . The problem is that links were formed a little differently on the old version of the site. As a result, in the new version I have projti-operacia
a need proiti-operaciy
. Do I need to write my own CNC generation method so that they correspond to the old version, or is it possible to somehow configure the zelenin/yii2-slug-behavior extension? Here is the code from the new version just in case:
public function behaviors(): array
{
return [
'slug' => [
'class' => 'Zelenin\yii\behaviors\Slug',
'slugAttribute' => 'slug',
'attribute' => 'question_name',
'ensureUnique' => true,
'replacement' => '-',
'lowercase' => true,
'immutable' => false,
'transliterateOptions' => 'Russian-Latin/BGN; Any-Latin; Latin-ASCII; NFD; [:Nonspacing Mark:] Remove; NFC;'
]
];
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question