Answer the question
In order to leave comments, you need to log in
How to use form with namespace in Yii 1?
For example, there is this form:
namespace application\modules\posts\models;
class PostSearch extends \CFormModel
{
}
Answer the question
In order to leave comments, you need to log in
class WebApplication extends \CWebApplication
{
public function init()
{
parent::init();
\CHtml::setModelNameConverter(
function ($model) {
$reflection = new \ReflectionClass($model);
return $reflection->getShortName();
}
);
}
}
in index.php
....
Yii::createApplication('WebApplication', $config)->run();
By means of framework in any way. But in yii2 this issue is resolved, why are you using junk?
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question