/** * * $filtering * if index page: * category_id * filter * sort * query */ public function toHTML($viewpage = 'index', $doReplace = false) { $data = $this->getData(); if (count($data->pages) == $this->get('pages.total') && $this->get('pages.total') == '1' || $this->get('pages.total') == 0) { return false; } $queries = ''; if (!empty($data) && $doReplace) { $curPageLink = 'index.php?option=com_easyblog&view=' . $viewpage . $queries; foreach ($data->pages as $page) { if (!empty($page->link)) { $limitstart = !empty($page->base) ? '&limitstart=' . $page->base : ''; $page->link = EasyBlogRouter::_($curPageLink . $limitstart); } } // newer link if (!empty($data->next->link)) { $limitstart = !empty($data->next->base) ? '&limitstart=' . $data->next->base : ''; $data->next->link = EasyBlogRouter::_($curPageLink . $limitstart); } // older link if (!empty($data->previous->link)) { $limitstart = !empty($data->previous->base) ? '&limitstart=' . $data->previous->base : ''; $data->previous->link = EasyBlogRouter::_($curPageLink . $limitstart); } } $theme = new CodeThemes(); $theme->set('data', $data); return $theme->fetch('blog.pagination.php'); }
/** * Shares a story through 3rd party oauth clients * * @param TableBlog $blog A blog table object * @param string $type The type of oauth client * * @return boolean True on success and false otherwise. **/ public function getHTML($bloggerid = "") { $html = ''; $my = JFactory::getUser(); $config = EasyBlogHelper::getConfig(); if ($config->get('main_jomsocial_messaging') && $my->id != $bloggerid) { $file_core = JPATH_ROOT . DIRECTORY_SEPARATOR . 'components' . DIRECTORY_SEPARATOR . 'com_community' . DIRECTORY_SEPARATOR . 'libraries' . DIRECTORY_SEPARATOR . 'core.php'; $file_messaging = JPATH_ROOT . DIRECTORY_SEPARATOR . 'components' . DIRECTORY_SEPARATOR . 'com_community' . DIRECTORY_SEPARATOR . 'libraries' . DIRECTORY_SEPARATOR . 'messaging.php'; if (file_exists($file_core) && file_exists($file_messaging)) { require_once $file_core; require_once $file_messaging; CMessaging::load(); $html = '<a href="javascript:void(0);" onclick="' . CMessaging::getPopup($bloggerid) . '" class="author-message" title="' . JText::_('COM_EASYBLOG_MESSAGE_AUTHOR') . '"><span>' . JText::_('COM_EASYBLOG_MESSAGE_AUTHOR') . '</span></a>'; } } $easysocial = EasyBlogHelper::getHelper('EasySocial'); if ($config->get('integrations_easysocial_conversations') && $easysocial->exists() && $my->id != $bloggerid) { $easysocial->init(); $user = Foundry::user($bloggerid); $theme = new CodeThemes(); $theme->set('user', $user); $html = $theme->fetch('easysocial.conversation.php'); } return $html; }
public function getAjaxTemplate() { $files = JRequest::getVar('names', ''); if (empty($files)) { return false; } // Ensure the integrity of each items submitted to be an array. if (!is_array($files)) { $files = array($files); } $result = array(); foreach ($files as $file) { $dashboard = explode('/', $file); if ($dashboard[0] == "dashboard") { $template = new CodeThemes(true); $out = $template->fetch($dashboard[1] . '.ejs'); } elseif ($dashboard[0] == "media") { $template = new CodeThemes(true); $out = $template->fetch("media." . $dashboard[1] . '.ejs'); } else { $template = new CodeThemes(); $out = $template->fetch($file . '.ejs'); } $obj = new stdClass(); $obj->name = $file; $obj->content = $out; $result[] = $obj; } header('Content-type: text/x-json; UTF-8'); $json = new Services_JSON(); echo $json->encode($result); exit; }
/** * Retrieves the html codes for the ratings. * * @param int $uid The unique id for the item that is being rated * @param string $type The unique type for the item that is being rated * @param string $command A textual representation to request user to vote for this item. * @param string $element A dom element id. **/ public function getHTML($uid, $type, $command, $elementId, $disabled = false) { $config = EasyBlogHelper::getConfig(); if (!$config->get('main_ratings')) { return false; } $language = JFactory::getLanguage(); $language->load('com_easyblog', JPATH_ROOT); // Add ratings to the page $document = JFactory::getDocument(); $rating = EasyBlogHelper::getTable('Ratings', 'Table'); $my = JFactory::getUser(); $hash = $my->id > 0 ? '' : JFactory::getSession()->getId(); $voted = $rating->fill($my->id, $uid, $type, $hash); $locked = $voted || $my->id < 1 && !$config->get('main_ratings_guests') || $disabled; $model = EasyBlogHelper::getModel('Ratings'); $ratingValue = $model->getRatingValues($uid, $type); $theme = new CodeThemes(); $theme->set('voted', $voted); $theme->set('elementId', $elementId); $theme->set('rating', $ratingValue->ratings); $theme->set('total', $ratingValue->total); $theme->set('locked', $locked); $theme->set('command', $command); $theme->set('uid', $uid); $theme->set('type', $type); return $theme->fetch('ratings.form.php'); }
public static function getHTML() { $captcha = EasyBlogHelper::getTable('Captcha', 'Table'); $captcha->created = EasyBlogHelper::getDate()->toMySQL(); $captcha->store(); $theme = new CodeThemes(); $theme->set('id', $captcha->id); return $theme->fetch('comment.captcha.php'); }
public function getHTML($content, $options) { $json = new Services_JSON(); $options = $json->encode($options); $themes = new CodeThemes(); $themes->set('content', $content); $themes->set('options', $options); return $themes->fetch('tooltip.php'); }
public static function getHTML($blog) { $theme = new CodeThemes(); $config = EasyBlogHelper::getConfig(); $siteId = $config->get('comment_livefyre_siteid'); $theme->set('siteId', $siteId); $theme->set('blog', $blog); $contents = $theme->fetch('comment.livefyre.php'); return $contents; }
public static function getHTML($blog) { $theme = new CodeThemes(); $file = JPATH_ROOT . DIRECTORY_SEPARATOR . 'components' . DIRECTORY_SEPARATOR . 'com_rscomments' . DIRECTORY_SEPARATOR . 'helpers' . DIRECTORY_SEPARATOR . 'rscomments.php'; if (!JFile::exists($file)) { return ''; } include_once $file; $theme->set('blog', $blog); return $theme->fetch('comment.rscomments.php'); }
public static function getAddThis() { $config = EasyBlogHelper::getConfig(); $addthis_customcode = $config->get('social_addthis_customcode', 'xa-4be11e1875bf6363'); $addthis_style = $config->get('social_addthis_style', '2'); $displayText = JText::_('COM_EASYBLOG_BOOKMARK'); $theme = new CodeThemes(); $theme->set('addthis_customcode', $addthis_customcode); $theme->set('displayText', $displayText); return $theme->fetch('addthis.button.style' . $addthis_style . '.php'); }
public static function getHTML($blog) { $theme = new CodeThemes(); $file = JPATH_ROOT . DIRECTORY_SEPARATOR . 'administrator' . DIRECTORY_SEPARATOR . 'components' . DIRECTORY_SEPARATOR . 'com_jomcomment' . DIRECTORY_SEPARATOR . 'config.jomcomment.php'; if (!JFile::exists($file)) { return ''; } include_once JPATH_PLUGINS . DIRECTORY_SEPARATOR . 'content' . DIRECTORY_SEPARATOR . 'jom_comment_bot.php'; $theme->set('blog', $blog); return $theme->fetch('comment.jomcomment.php'); }
public function show() { $theme = new CodeThemes(); $ajax = EasyBlogHelper::getHelper('Ajax'); $type = JRequest::getCmd('type'); $id = JRequest::getInt('id'); $theme->set('id', $id); $theme->set('type', $type); $contents = $theme->fetch('ajax.dialog.report.form.php'); $ajax->success(JText::_('COM_EASYBLOG_REPORT_THIS_BLOG_POST'), $contents); $ajax->send(); }
public static function getHTML($blog) { $config = EasyBlogHelper::getConfig(); $theme = new CodeThemes(); $code = $config->get('comment_intensedebate_code'); if (empty($code)) { return ''; } $theme->set('code', $code); $theme->set('blog', $blog); return $theme->fetch('comment.intensedebate.php'); }
public function getItems() { $catid = $this->get('ezb_catfilter') ? $this->get('ezb_catid', NULL) : ''; $ordering = $this->get('ezb_ordering', 'latest'); $user = JFactory::getUser(); $category = EasyBlogHelper::getTable('Category', 'Table'); $category->load($catid); if ($category->private && $user->id == 0) { echo JText::_('This category is set to private'); return; } if (!class_exists('EasyBlogModelBlog')) { jimport('joomla.application.component.model'); JLoader::import('blog', EBLOG_ROOT . '/' . 'models'); } $model = EasyBlogHelper::getModel('Blog'); if ($this->get('ezfeatured')) { $items = $model->getFeaturedBlog($catid, $this->get('count')); } else { $items = $model->getBlogsBy('category', $catid, $ordering, $this->get('count'), EBLOG_FILTER_PUBLISHED, null, false); } $config = EasyBlogHelper::getConfig(); if (!empty($items)) { for ($i = 0; $i < count($items); $i++) { $row =& $items[$i]; $author = EasyBlogHelper::getTable('Profile', 'Table'); $row->author = $author->load($row->created_by); $row->commentCount = EasyBlogHelper::getCommentCount($row->id); $requireVerification = false; if ($config->get('main_password_protect', true) && !empty($row->blogpassword)) { $row->title = JText::sprintf('COM_EASYBLOG_PASSWORD_PROTECTED_BLOG_TITLE', $row->title); $requireVerification = true; } if ($requireVerification && !EasyBlogHelper::verifyBlogPassword($row->blogpassword, $row->id)) { $theme = new CodeThemes(); $theme->set('id', $row->id); $theme->set('return', base64_encode(EasyBlogRouter::_('index.php?option=com_easyblog&view=entry&id=' . $row->id))); $row->introtext = $theme->fetch('blog.protected.php'); $row->content = $row->introtext; $row->showRating = false; $row->protect = true; } else { $row->introtext = EasyBlogHelper::getHelper('Videos')->strip($row->content); $row->showRating = true; $row->protect = false; } } //end foreach } //XEFUtility::debug($items); $items = $this->prepareItems($items); return $items; }
public static function getHTML($blog) { $theme = new CodeThemes(); $document = JFactory::getDocument(); $language = $document->getLanguage(); $language = explode('-', $language); if (count($language) != 2) { $language = array('en', 'GB'); } $theme->set('language', $language); $theme->set('blog', $blog); return $theme->fetch('comment.facebook.php'); }
function showSubscription($bloggerId) { $my = JFactory::getUser(); $ejax = new Ejax(); $tpl = new CodeThemes(); $tpl->set('my', $my); $tpl->set('blogId', $bloggerId); $options = new stdClass(); $options->title = JText::_('COM_EASYBLOG_SUBSCRIBE_BLOGGER'); $options->content = $tpl->fetch('blogger.subscription.box.php'); $ejax->dialog($options); $ejax->send(); return; }
public static function getHTML($blog) { $config = EasyBlogHelper::getConfig(); $theme = new CodeThemes(); $code = $config->get('comment_disqus_code'); if (empty($code)) { return ''; } $code = JString::str_ireplace('Please enable JavaScript to view the comments powered by Disqus.', '', $code); $code = JString::str_ireplace('blog comments powered by Disqus', '', $code); $theme->set('code', $code); $theme->set('blog', $blog); return $theme->fetch('comment.disqus.php'); }
public function getHTML($bloggerid = "") { $config = EasyBlogHelper::getConfig(); $html = ''; $easysocial = EasyBlogHelper::getHelper('EasySocial'); if ($config->get('integrations_easysocial_badges') && $easysocial->exists()) { $easysocial->init(); $user = Foundry::user($bloggerid); $badges = $user->getBadges(); $theme = new CodeThemes(); $theme->set('badges', $badges); $html = $theme->fetch('easysocial.achievements.php'); } return $html; }
public function showVoters($elementId, $type) { $ajax = new Ejax(); $model = $this->getModel('Ratings'); $config = EasyBlogHelper::getConfig(); $voters = $model->getRatingUsers($elementId, $type, $config->get('main_ratings_display_raters_max')); $guests = false; $theme = new CodeThemes(); $theme->set('guests', $guests); $theme->set('voters', $voters); $options = new stdClass(); $options->title = JText::_('COM_EASYBLOG_DIALOG_TITLE_RECENT_VOTERS'); $options->content = $theme->fetch('ratings.users.php'); $ajax->dialog($options); return $ajax->send(); }
function getView($name = '', $type = '', $prefix = '', $config = array()) { $file = $name; $dashboard = explode('/', $file); if ($dashboard[0] == "dashboard") { $template = new CodeThemes(true); $out = $template->fetch($dashboard[1] . '.ejs'); } elseif ($dashboard[0] == "media") { $template = new CodeThemes(true); $out = $template->fetch("media." . $dashboard[1] . '.ejs'); } else { $template = new CodeThemes(); $out = $template->fetch($file . '.ejs'); } return $out; }
function loadCalendar($position = 'module', $itemId = '0', $size = 'small', $type = 'blog', $timestamp = '') { $my = JFactory::getUser(); $ajax = new Ejax(); $config = EasyBlogHelper::getConfig(); $tpl = new CodeThemes(); $model = new EasyBlogModelArchive(); $allowed = array('module', 'component'); if (!in_array($position, $allowed)) { return; } if (!empty($itemId)) { JRequest::setVar('Itemid', $itemId); } //get date. $date = EasyBlogCalendarHelper::processDate($timestamp); //get the required data to build the calendar. $data = EasyBlogCalendarHelper::prepareData($date); //get the postcount //$postCount = $model->getArchivePostCountByMonth($date['month'], $date['year']); $postData = $model->getArchivePostByMonth($date['month'], $date['year']); switch ($position) { case 'module': $namespace = 'mod_easyblogcalendar'; $preFix = 'mod_easyblog'; $ajax->script('mod_easyblogcalendar.calendar.setItemId("' . $itemId . '");'); break; case 'component': $namespace = 'eblog'; $preFix = 'com_easyblog'; break; } $previous = $namespace . '.calendar.reload( \'archive\' , \'loadCalendar\', \'' . $position . '\', \'' . $itemId . '\', \'' . $size . '\', \'' . $type . '\', \'' . $data->previous . '\');'; $next = $namespace . '.calendar.reload( \'archive\' , \'loadCalendar\', \'' . $position . '\', \'' . $itemId . '\', \'' . $size . '\', \'' . $type . '\', \'' . $data->next . '\');'; $tpl->set('calendar', $data); $tpl->set('date', $date); $tpl->set('postData', $postData); $tpl->set('previous', $previous); $tpl->set('next', $next); $tpl->set('namespace', $namespace); $tpl->set('preFix', $preFix); $tpl->set('itemId', $itemId); $layout = $tpl->fetch('calendar.' . $size . '.php'); $ajax->assign('easyblogcalendar-' . $position . '-wrapper', $layout); $ajax->send(); return; }
public function getRanks($userId) { $config = EasyBlogHelper::getConfig(); if (!$config->get('main_alpha_userpoint_ranks')) { return false; } if (!$this->loadHelper()) { return false; } if (!method_exists('AlphaUserPointsHelper', 'getUserRank')) { return false; } $rank = AlphaUserPointsHelper::getUserRank('', $userId); $theme = new CodeThemes(); $theme->set('rank', $rank); return $theme->fetch('author.aup.ranks.php'); }
function getView($name = '', $type = '', $prefix = '', $config = array()) { // Load language support for front end and back end. JFactory::getLanguage()->load('com_easyblog', JPATH_ROOT . DIRECTORY_SEPARATOR . 'administrator'); JFactory::getLanguage()->load('com_easyblog', JPATH_ROOT); $file = $name; $dashboard = explode('/', $file); if ($dashboard[0] == "dashboard") { $template = new CodeThemes(true); $out = $template->fetch($dashboard[1] . '.ejs'); } elseif ($dashboard[0] == "media") { $template = new CodeThemes(true); $out = $template->fetch("media." . $dashboard[1] . '.ejs'); } else { $template = new CodeThemes(); $out = $template->fetch($file . '.ejs'); } return $out; }
public function showVideoForm($editorName) { $ajax = new Ejax(); $my = JFactory::getUser(); if ($my->id <= 0) { $title = JText::_('COM_EASYBLOG_INFO'); $callback = JText::_('COM_EASYBLOG_NO_PERMISSION_TO_PUBLISH_OR_UNPUBLISH_COMMENT'); $width = '450'; $height = 'auto'; $ajax->alert($callback, $title, $width, $height); $ajax->send(); return; } $theme = new CodeThemes(true); $theme->set('editorName', $editorName); $content = $theme->fetch('ajax.dialog.videos.add.php'); $title = JText::_('COM_EASYBLOG_DASHBOARD_WRITE_INSERT_VIDEO_DIALOG_TITLE'); $ajax->dialog(EasyBlogHelper::getHelper('DialogOptions')->set('title', $title)->set('content', $content)->toObject()); return $ajax->send(); }
function getHTML($blogId) { $config = EasyBlogHelper::getConfig(); $my = JFactory::getUser(); $pdfEnabled = $config->get('layout_enablepdf'); $printEnabled = $config->get('layout_enableprint'); // check if pdf enabled if ($pdfEnabled == '2') { if ($my->id == 0) { $pdfEnabled = 0; } } // check if pdf enabled if ($printEnabled == '2') { if ($my->id == 0) { $printEnabled = 0; } } $theme = new CodeThemes(); $theme->set('blogId', $blogId); $theme->set('pdfEnabled', $pdfEnabled); $theme->set('printEnabled', $printEnabled); $theme->set('pdfLinkProperties', EasyBlogHelper::getPDFlinkProperties()); $html = $theme->fetch('blog.publishing.tool.php'); $bookmark = EasyBlogBookmark::getHTML(); return $html . $bookmark; }
/** * Displays the files and folders that are in the media manager. */ public function display($tpl = null) { $config = EasyBlogHelper::getConfig(); $document = JFactory::getDocument(); $my = JFactory::getUser(); $app = JFactory::getApplication(); $profile = EasyBlogHelper::getTable('Profile'); $profile->load($my->id); if ($my->id <= 0) { echo JText::_('COM_EASYBLOG_NOT_ALLOWED'); exit; } $user = JFactory::getUser(); $document->setTitle(JText::_('COM_EASYBLOG_MEDIA_MANAGER')); // Only allow admin to impersonate anyone. if (EasyBlogHelper::isSiteAdmin()) { $user = JFactory::getUser(JRequest::getVar('blogger_id', $my->id)); } $debug = $config->get('debug_javascript') || JRequest::getVar('ebjsdebug') == 1 ? 'true' : 'false'; $theme = new CodeThemes(true); $theme->set('debug', $debug); $theme->set('session', JFactory::getSession()); $theme->set('blogger_id', $user->id); // @rule: Test if the user is already associated with Flickr $oauth = EasyBlogHelper::getTable('Oauth'); $associated = $oauth->loadByUser($my->id, EBLOG_OAUTH_FLICKR); $theme->set('flickrAssociated', $associated); echo $theme->fetch('media.php'); }
function showDialog($teamId, $type = 'join') { $my = JFactory::getUser(); $ejax = new Ejax(); $config = EasyBlogHelper::getConfig(); if ($my->id <= 0) { echo JText::_('COM_EASYBLOG_NOT_ALLOWED'); return; } $team = EasyBlogHelper::getTable('TeamBlog', 'Table'); $team->load($teamId); $theme = new CodeThemes(); $theme->set('team', $team); $messageText = $type == 'join' ? 'COM_EASYBLOG_TEAMBLOG_DIALOG_JOIN_TEAM_TITLE' : 'COM_EASYBLOG_TEAMBLOG_DIALOG_LEAVE_TEAM_TITLE'; $template = $type == 'join' ? 'ajax.dialog.team.join.php' : 'ajax.dialog.team.leave.php'; $options = new stdClass(); $options->title = JText::_($messageText); $options->content = $theme->fetch($template); $ejax->dialog($options); $ejax->send(); return; }
public function getHTML($bloggerid = "") { $html = ''; $my = JFactory::getUser(); $config = EasyBlogHelper::getConfig(); // We don't want to show the link to the same user if ($my->id == $bloggerid) { return; } if ($config->get('main_jomsocial_friends')) { $file_core = JPATH_ROOT . DIRECTORY_SEPARATOR . 'components' . DIRECTORY_SEPARATOR . 'com_community' . DIRECTORY_SEPARATOR . 'libraries' . DIRECTORY_SEPARATOR . 'core.php'; $file_messaging = JPATH_ROOT . DIRECTORY_SEPARATOR . 'components' . DIRECTORY_SEPARATOR . 'com_community' . DIRECTORY_SEPARATOR . 'libraries' . DIRECTORY_SEPARATOR . 'friends.php'; jimport('joomla.filesystem.file'); if (JFile::exists($file_core) && JFile::exists($file_messaging)) { require_once $file_core; require_once $file_messaging; $user = CFactory::getUser(); $model = CFactory::getModel('Friends'); $friends = $model->getFriendIds($bloggerid); if (!in_array($my->id, $friends)) { CFriends::load(); $html = '<a href="javascript:void(0);" onclick="' . CFriends::getPopup($bloggerid) . '" class="author-friend"><span>' . JText::_('COM_EASYBLOG_ADD_FRIEND') . '</span></a>'; } } } $easysocial = EasyBlogHelper::getHelper('EasySocial'); if ($config->get('integrations_easysocial_friends') && $easysocial->exists()) { $user = Foundry::user($bloggerid); // Check if the user is friends with the current viewer. if ($user->isFriends($my->id)) { return; } $easysocial->init(); $theme = new CodeThemes(); $theme->set('id', $bloggerid); $html = $theme->fetch('easysocial.friends.php'); } return $html; }
public function getHTML($bloggerid = "") { $html = ''; $my = JFactory::getUser(); $config = EasyBlogHelper::getConfig(); // We don't want to show the link to the same user if ($my->id == $bloggerid) { return; } $easysocial = EasyBlogHelper::getHelper('EasySocial'); if ($config->get('integrations_easysocial_followers') && $easysocial->exists()) { $user = Foundry::user($bloggerid); $followed = $user->isFollowed($my->id); if ($followed) { return; } $easysocial->init(); $theme = new CodeThemes(); $theme->set('id', $bloggerid); $html = $theme->fetch('easysocial.followers.php'); } return $html; }
public function search($query = '') { $ajax = new Ejax(); $model = $this->getModel('Search'); $result = $model->searchText($query); if (empty($result)) { $ajax->script('$("#editor-content .search-results-content").height(24);'); $ajax->assign('editor-content .search-results-content', JText::_('COM_EASYBLOG_DASHBOARD_WRITE_SEARCH_NO_RESULT')); return $ajax->send(); } $count = count($result); if ($count > 10) { $height = "240"; } else { $height = "24" * $count; } $theme = new CodeThemes('dashboard'); $theme->set('result', $result); $ajax->assign('editor-content .search-results-content', $theme->fetch('dashboard.write.search.result.php')); $ajax->script('$("#editor-content .search-results-content").height(' . $height . ');'); $ajax->script('$("#editor-content .search-results-content").show();'); // $ajax->script( 'eblog.fileManager.setDockLayout();' ); return $ajax->send(); }
function display($tmpl = null) { JPluginHelper::importPlugin('easyblog'); $dispatcher = JDispatcher::getInstance(); $mainframe = JFactory::getApplication(); $document = JFactory::getDocument(); $config = EasyBlogHelper::getConfig(); $acl = EasyBlogACLHelper::getRuleSet(); if (!EasyBlogRouter::isCurrentActiveMenu('featured')) { $this->setPathway(JText::_('COM_EASYBLOG_FEATURED_BREADCRUMB')); } // set meta tags for featured view EasyBlogHelper::setMeta(META_ID_FEATURED, META_TYPE_VIEW); EasyBlogHelper::getHelper('Feeds')->addHeaders('index.php?option=com_easyblog&view=featured'); $model = $this->getModel('Featured'); $data = $model->getFeaturedBlog(); $pagination = $model->getPagination(); $params = $mainframe->getParams('com_easyblog'); $data = EasyBlogHelper::formatBlog($data); $blogModel = $this->getModel('Blog'); $pageNumber = $pagination->get('pages.current'); $pageText = $pageNumber == 1 ? '' : ' - ' . JText::sprintf('COM_EASYBLOG_PAGE_NUMBER', $pageNumber); $document->setTitle(EasyBlogHelper::getPageTitle(JText::_('COM_EASYBLOG_FEATURED_PAGE_TITLE') . $pageText)); if ($config->get('layout_showcomment', false)) { for ($i = 0; $i < count($data); $i++) { $row =& $data[$i]; $maxComment = $config->get('layout_showcommentcount', 3); $comments = EasyBlogHelper::getHelper('Comment')->getBlogComment($row->id, $maxComment, 'desc'); $comments = EasyBlogHelper::formatBlogCommentsLite($comments); $row->comments = $comments; } } $theme = new CodeThemes(); $theme->set('data', $data); $theme->set('pagination', $pagination->getPagesLinks()); $theme->set('currentURL', 'index.php?option=com_easyblog&view=featured'); $theme->set('siteadmin', EasyBlogHelper::isSiteAdmin()); $theme->set('config', $config); $theme->set('acl', $acl); echo $theme->fetch('blog.featured.php'); }