Current Path :
/
home
/
develito
/
www
/
components
/
com_dmod
/
helpers
/
Or
Select Your Path :
Upload File :
New :
File
Dir
/home/develito/www/components/com_dmod/helpers/icon.php
<?php /*------------------------------------------------------------------------ # com_dmod - Dmod Module Manager # ------------------------------------------------------------------------ # author Jesus Vargas Garita # copyright Copyright (C) 2010 www.joomlahill.com. All Rights Reserved. # @license - http://www.gnu.org/licenses/gpl-2.0.html GNU/GPL # Websites: http://www.joomlahill.com # Technical Support: Forum - http://www.joomlahill.com/forum -------------------------------------------------------------------------*/ // No direct access defined('_JEXEC') or die; class JHTMLIcon { static function email($contact, $params, $attribs = array()) { $uri = JURI::getInstance(); $base = $uri->toString(array('scheme', 'host', 'port')); $link = $base.JRoute::_(ContentHelperRoute::getArticleRoute($article->slug, $article->catid) , false); $url = 'index.php?option=com_mailto&tmpl=component&link='.base64_encode($link); $status = 'width=400,height=350,menubar=yes,resizable=yes'; if ($params->get('show_icons')) { $text = JHtml::_('image','system/emailButton.png', JText::_('JGLOBAL_EMAIL'), NULL, true); } else { $text = ' '.JText::_('JGLOBAL_EMAIL'); } $attribs['title'] = JText::_('JGLOBAL_EMAIL'); $attribs['onclick'] = "window.open(this.href,'win2','".$status."'); return false;"; $output = JHtml::_('link',JRoute::_($url), $text, $attribs); return $output; } static function print_popup($article, $params, $attribs = array()) { $url = ContentHelperRoute::getContactRoute($contact->slug, $contact->catid); $url .= '&tmpl=component&print=1&layout=default&page='.@ $request->limitstart; $status = 'status=no,toolbar=no,scrollbars=yes,titlebar=no,menubar=no,resizable=yes,width=640,height=480,directories=no,location=no'; // checks template image directory for image, if non found default are loaded if ($params->get('show_icons')) { $text = JHtml::_('image','system/printButton.png', JText::_('JGLOBAL_PRINT'), NULL, true); } else { $text = JText::_('JGLOBAL_ICON_SEP') .' '. JText::_('JGLOBAL_PRINT') .' '. JText::_('JGLOBAL_ICON_SEP'); } $attribs['title'] = JText::_('JGLOBAL_PRINT'); $attribs['onclick'] = "window.open(this.href,'win2','".$status."'); return false;"; $attribs['rel'] = 'nofollow'; return JHtml::_('link',JRoute::_($url), $text, $attribs); } static function print_screen($contact, $params, $attribs = array()) { // checks template image directory for image, if non found default are loaded if ($params->get('show_icons')) { $text = JHtml::_('image','system/printButton.png', JText::_('JGLOBAL_PRINT'), NULL, true); } else { $text = JText::_('JGLOBAL_ICON_SEP') .' '. JText::_('JGLOBAL_PRINT') .' '. JText::_('JGLOBAL_ICON_SEP'); } return '<a href="#" onclick="window.print();return false;">'.$text.'</a>'; } }