My portlet
is unable to render the view;
This is how i call the portlet:
$this->widget('ModalConfirmDelete', array(
'type_domain_or_url' => 'domain',
));
This is my portlet:
<?php
class ModalConfirmDelete extends CPortlet {
public $type_domain_or_url;
public function init() {
parent::init();
}
/**
* Renders the content of the portlet.
*/
protected function renderContent() {
$this->render(dirname(__FILE__) . '/views/modal_confirm_delete', array(
'type_domain_or_url' => $this->type_domain_or_url,
));
}
}
The view is located under the same directory as the portlet, but within the views
child folder;
Why do i get the exception?
CException
ModalConfirmDelete cannot find the view "/var/www/html/HeadQuarter/frontend/protected/portlets/views/modal_confirm_delete"
Solved; for some reason, the path was not needed;
I just wrote the view name;
On other projects I had to specify the path;