item = $this->get('Item'); $this->state = $this->get('State'); $this->params = $this->state->get('params'); // Create a shortcut for $item. $item = $this->item; $offset = $this->state->get('list.offset'); $dispatcher->trigger('onContentPrepare', array ('com_weblinks.weblink', &$item, &$item->params, $offset)); $item->event = new stdClass; $results = $dispatcher->trigger('onContentAfterTitle', array('com_weblinks.weblink', &$item, &$item->params, $offset)); $item->event->afterDisplayTitle = trim(implode("\n", $results)); $results = $dispatcher->trigger('onContentBeforeDisplay', array('com_weblinks.weblink', &$item, &$item->params, $offset)); $item->event->beforeDisplayContent = trim(implode("\n", $results)); $results = $dispatcher->trigger('onContentAfterDisplay', array('com_weblinks.weblink', &$item, &$item->params, $offset)); $item->event->afterDisplayContent = trim(implode("\n", $results)); parent::display($tpl); } }