Ejemplo n.º 1
0
 /**
  * This displays the content article
  * specified in the plugin's params
  *
  * @return unknown_type
  */
 function _displayArticle()
 {
     $html = '';
     $articleid = (int) $this->params->get('articleid');
     if ($articleid && is_int($articleid)) {
         require_once JPATH_ADMINISTRATOR . '/components/com_j2store/library/j2item.php';
         $html = J2StoreItem::display($articleid);
     }
     return $html;
 }
Ejemplo n.º 2
0
 public function getTerms()
 {
     $app = JFactory::getApplication();
     $id = $app->input->getInt('article_id');
     require_once JPATH_COMPONENT_ADMINISTRATOR . '/library/j2item.php';
     $j2item = new J2StoreItem();
     $data = $j2item->display($id);
     $view = $this->getView('checkout', 'html');
     $view->set('_controller', 'checkout');
     $view->set('_view', 'checkout');
     $view->set('_doTask', true);
     $view->set('hidemenu', true);
     $view->assign('html', $data);
     $view->setLayout('checkout_terms');
     ob_start();
     $view->display();
     $html = ob_get_contents();
     ob_end_clean();
     echo $html;
     $app->close();
 }