Detailed Description
Definition at line 5 of file BaseWidget.php.
Member Function Documentation
BaseWidget::getViewFile |
( |
|
$viewName | ) |
|
Overridden function for using widget views from custom section
- Parameters
-
- Returns
- mixed|string
Definition at line 14 of file BaseWidget.php.
{
if (isset(Yii::app()->params['customViews']) && Yii::app()->params['customViews'] == true) {
$customSection = realpath(Yii::getPathOfAlias('site.custom'));
$commonSection = realpath(Yii::getPathOfAlias('site.common'));
$frontendSection = realpath(Yii::getPathOfAlias('site.frontend'));
$customView = str_replace(array($commonSection, $frontendSection), $customSection, $viewFile);
if (file_exists($customView)) {
return $customView;
}
}
return $viewFile;
}
The documentation for this class was generated from the following file: