the following codes are called from view files, and assume the file to be included is named partial.php.
to render a view from the current controller, ie view files are from the same directory:
PHP:
$this->renderPartial('partial'); |
to render a view from a another model:
PHP:
$this->renderPartial('/<model name>/partial'); |
to render a view from a module:
PHP:
$this->renderPartial('<module name>.views.<model name>.partial'); |
Leave a comment