Display Joomla component within a module -
i'm trying display joomla 2.5 component in module. in module entrypoint have:
jloader::import('joomla.application.component.model'); jloader::import( 'quizzes', jpath_site . '/components/com_questions/models' ); jloader::import('joomla.application.component.controller'); if (!class_exists('questionscontrollerquizzes')) { require_once (jpath_site . ds . 'components' . ds . 'com_questions/controllers' . ds . 'quizzes.php'); } $quiz_controller = new questionscontrollerquizzes(false, $params->get('poll')); $quiz_controller->execute( jrequest::getvar('task','load') );
i tried debug , seems can't load correct view. seems looking generic com_content in $this->basepath.
the strange thing if load module in page component loaded, display correctly.
any idea how succesfully display component output in module?
try this: how display joomla component in module
and remember controller should include function task!
Comments
Post a Comment