Exemplo n.º 1
0
 public function getProfileLink($user_id, &$object, &$attribs = array())
 {
     $user = CFactory::getUser($user_id);
     //parameters
     $params = $this->params;
     if (!$user || $params->get('view_individual_link', '1') == 0) {
         return true;
     }
     JHTML::_('behavior.tooltip');
     $name = $user->getDisplayName();
     $url = CRoute::_('index.php?option=com_community&view=profile&userid=' . $user_id);
     switch ($params->get('view_individual_link', '1')) {
         case 2:
             $avatar = $user->getThumbAvatar();
             $text = '<img class="hasTip" src="' . $avatar . '" title="' . $name . '"/>';
             break;
         case 1:
         default:
             $text = JText::_('PLG_TRACKS_JOMSOCIAL_VIEW_USER_PROFILE');
             break;
     }
     $attribs = array_merge($attribs, array('alt' => $user->get('username')));
     $object->text = JHTML::link($url, $text, $attribs);
     return true;
 }
Exemplo n.º 2
0
 function draw_help($help)
 {
     echo '<h3>' . $help['name'] . ': ' . JText::_($help['prefix'] . '_HELP_TITLE') . '</h3>';
     echo '<p><span style="font-size:120%;font-weight:bold;">' . JText::sprintf($help['prefix'] . '_HELP_RATING', $help['name']) . ' ';
     echo JHTML::link($help['link_rating'], 'Joomla Extensions Directory', 'target="_blank"') . '</span></p>';
     $version_info = $this->get_version_info($help['reference'], $help['current_version']);
     if (!empty($version_info['message'])) {
         echo $version_info['message'];
     }
     $k = 0;
     echo '<table class="help_support">';
     echo '<tr class="row' . $k . '"><td>' . JText::_($help['prefix'] . '_VERSION') . '</td>';
     echo '<td>' . $help['current_version'] . '</td></tr>';
     if (!empty($version_info['latest_version'])) {
         $k = 1 - $k;
         echo '<tr class="row' . $k . '"><td>' . JText::_($help['prefix'] . '_LATEST_VERSION') . '</td>';
         echo '<td>' . $version_info['latest_version'] . '</td></tr>';
     }
     $k = 1 - $k;
     echo '<tr class="row' . $k . '"><td>' . JText::_($help['prefix'] . '_HELP_CHECK') . '</td>';
     echo '<td>' . JHTML::link($help['link_version'], 'Les Arbres Design - ' . $help['name'], 'target="_blank"') . '</td></tr>';
     $pdf_icon = JHTML::_('image', JURI::root() . 'administrator/components/com_' . $help['reference'] . '/assets/pdf_16.gif', '', 'style="vertical-align:middle;border:none;padding:0;margin:0;"');
     $k = 1 - $k;
     echo '<tr class="row' . $k . '"><td>' . $pdf_icon . ' ' . JText::_($help['prefix'] . '_HELP_DOC') . '</td>';
     echo '<td>' . JHTML::link($help['link_doc'], "www.lesarbresdesign.info", 'target="_blank"') . '</td></tr>';
     $k = 1 - $k;
     echo '<tr class="row' . $k . '"><td>' . JText::_($help['prefix'] . '_HELP_LES_ARBRES') . '</td><td>' . JHTML::link("http://www.lesarbresdesign.info/", 'Les Arbres Design', 'target="_blank"') . '</td></tr>';
     if (!empty($help['extra'])) {
         foreach ($help['extra'] as $row) {
             $k = 1 - $k;
             echo '<tr class="row' . $k . '"><td>' . $row['left'] . '</td><td>' . $row['right'] . '</td></tr>';
         }
     }
     echo '</table>';
 }
Exemplo n.º 3
0
    /**
     * Creates the buttons view
     *
     * @param string $link targeturl
     * @param string $image path to image
     * @param string $text image description
     * @param boolean $modal 1 for loading in modal
     */
    function quickiconButton($link, $image, $text, $modal = 0)
    {
        //initialise variables
        $lang =& JFactory::getLanguage();
        ?>

    <div style="float:<?php 
        echo $lang->isRTL() ? 'right' : 'left';
        ?>
;">
      <div class="icon">
        <?php 
        $html = JHTML::_('image', 'administrator/images/' . $image, $text) . '<span>' . $text . '</span>';
        if ($modal == 1) {
            JHTML::_('behavior.modal');
            $imagelink = JHTML::link($link . '&tmpl=component', $html, array('style' => "cursor:pointer", 'class' => 'modal', 'rel' => "{handler: 'iframe', size: {x: 650, y: 400}}"));
        } else {
            $imagelink = JHTML::link($link, $html);
        }
        echo $imagelink;
        ?>
      </div>
    </div>
    <?php 
    }
Exemplo n.º 4
0
 /**
  * Check upgrade / database status
  */
 function initCheck()
 {
     global $mainframe;
     // Check Plugins DB
     if (!$this->checkTableContents('plugins')) {
         $link = JHTML::link('index.php?option=com_jce&amp;task=repair&amp;type=plugins', JText::_('DB CREATE RESTORE'));
         return $this->redirect(JText::_('DB PLUGINS ERROR') . ' - ' . $link, 'error');
     }
     // Check Groups DB
     if (!$this->checkTableContents('groups')) {
         $link = JHTML::link('index.php?option=com_jce&amp;task=repair&amp;type=groups', JText::_('DB CREATE RESTORE'));
         return $this->redirect(JText::_('DB GROUPS ERROR') . ' - ' . $link, 'error');
     }
     // Check Editor is installed
     if (!$this->checkEditorFiles()) {
         return $this->redirect(JText::_('EDITOR FILES ERROR'), 'error');
     }
     if (!$this->checkEditor() && $this->checkEditorFiles()) {
         $link = JHTML::link('index.php?option=com_jce&amp;task=repair&amp;type=editor', JText::_('EDITOR INSTALL'));
         return $this->redirect(JText::_('EDITOR INSTALLED MANUAL ERROR') . ' - ' . $link, 'error');
     }
     // Check Editor is installed
     if (!$this->checkEditor()) {
         return $this->redirect(JText::_('EDITOR INSTALLED ERROR'), 'error');
     }
     // Check Editor is enabled
     if (!$this->checkEditorEnabled()) {
         return $this->redirect(JText::_('EDITOR ENABLED ERROR'), 'error');
     }
     // Check Update
     if (!$this->checkUpdate()) {
         $link = JHTML::link('index.php?option=com_jce&amp;task=repair&amp;type=update', JText::_('DB UPDATE'));
         return $this->redirect(JText::_('DB UPDATE MSG') . ' - ' . $link, 'error');
     }
 }
Exemplo n.º 5
0
 function display($tpl = null)
 {
     wfimport('admin.models.updates');
     $mainframe = JFactory::getApplication();
     $model = $this->getModel();
     $installer = WFInstaller::getInstance();
     $version = $model->getVersion();
     // Check Groups DB
     if (!$installer->profiles) {
         $link = JHTML::link('index.php?option=com_jce&amp;task=repair&amp;table=profiles', WFText::_('WF_DB_CREATE_RESTORE'));
         $mainframe->enqueueMessage(WFText::_('WF_DB_PROFILES_ERROR') . ' - ' . $link, 'error');
     }
     $component = WFExtensionHelper::getComponent();
     // get params definitions
     $params = new WFParameter($component->params, '', 'preferences');
     $canUpdate = WFModelUpdates::canUpdate();
     $options = array('feed' => (int) $params->get('feed', 0), 'updates' => (int) $params->get('updates', $canUpdate ? 1 : 0), 'labels' => array('feed' => WFText::_('WF_CPANEL_FEED_LOAD'), 'updates' => WFText::_('WF_UPDATES'), 'updates_available' => WFText::_('WF_UPDATES_AVAILABLE')));
     $this->document->addScript('components/com_jce/media/js/cpanel.js?version=' . $model->getVersion());
     $this->document->addScriptDeclaration('jQuery(document).ready(function($){$.jce.CPanel.init(' . json_encode($options) . ')});');
     WFToolbarHelper::preferences();
     WFToolbarHelper::updates($canUpdate);
     WFToolbarHelper::help('cpanel.about');
     $this->assignRef('icons', $icons);
     $this->assignRef('model', $model);
     $this->assignRef('installer', $installer);
     $this->assignRef('params', $params);
     $this->assignRef('version', $version);
     parent::display($tpl);
 }
Exemplo n.º 6
0
    function display($tpl = null)
    {
        FCP_Admin::make_title('COM_FLEXICONTACT_LOG');
        JToolBarHelper::cancel('display');
        // get the filter states
        $app = JFactory::getApplication();
        $filter_date = $app->getUserStateFromRequest(LAFC_COMPONENT . '.filter_date', 'filter_date', LAFC_LOG_ALL, 'int');
        // make the filter lists
        $date_filters = array(LAFC_LOG_ALL => JText::_('COM_FLEXICONTACT_LOG_ALL'), LAFC_LOG_LAST_12_MONTHS => JText::_('COM_FLEXICONTACT_LOG_LAST_12_MONTHS'));
        $lists['date'] = FCP_Common::make_list('filter_date', $filter_date, $date_filters, 0, 'onchange="submitform( );"');
        // show the chart
        ?>
<form action="index.php" method="get" name="adminForm" id="adminForm">
<input type="hidden" name="option" value="<?php 
        echo LAFC_COMPONENT;
        ?>
" />
<input type="hidden" name="task" value="stats" />
<input type="hidden" name="controller" value="log" />

<table>
	<tr>
		<td align="left" width="100%">
		<?php 
        echo '<strong>' . $this->title . '</strong>';
        ?>
		</td>
		<td nowrap="nowrap">
			<?php 
        echo $lists['date'];
        echo '&nbsp;';
        echo '<button class="fcp_button" onclick="' . "\n\t\t\t\t\tthis.form.getElementById('filter_date').value='" . LAFC_LOG_ALL . "';\n\t\t\t\t\tthis.form.submit();" . '">' . JText::_('COM_FLEXICONTACT_RESET') . '</button>';
        ?>
		</td>
	</tr>
</table>
</form>
<?php 
        if (strpos($this->data, 'script type')) {
            $document = JFactory::getDocument();
            $document->addScript("https://www.google.com/jsapi");
            // load the Google jsapi
            $document->addCustomTag($this->data);
            // load the chart script
            echo '<div id="chart_1"></div>';
            // create an element for the chart to be drawn in
        } else {
            echo $this->data;
        }
        echo '<h3>' . JText::sprintf('COM_FLEXICONTACT_LOG_ROWS', $this->num_rows) . '</h3>';
        ?>
<div align="right"><?php 
        echo JText::_('COM_FLEXICONTACT_POWERED_BY') . ' ' . JHTML::link(PLOTALOT_LINK, "Plotalot", 'target="_blank"');
        ?>
</div>
<?php 
    }
Exemplo n.º 7
0
 public function getProfileLink($user_id, &$object, &$attribs = '')
 {
     $user = JFactory::getUser($user_id);
     if (!$user->get('id')) {
         return true;
     }
     $link = JRoute::_('index.php?option=com_comprofiler&&task=userProfile&user='******'PLG_TRACKS_CB_VIEW_USER_PROFILE'), $attribs);
     return true;
 }
Exemplo n.º 8
0
    function display($tpl = null)
    {
        FCP_Admin::make_title('COM_FLEXICONTACT_LOG');
        JToolBarHelper::cancel();
        ?>
	<form action="index.php" method="post" name="adminForm" id="adminForm" >
	<input type="hidden" name="option" value="<?php 
        echo LAFC_COMPONENT;
        ?>
" />
	<input type="hidden" name="controller" value="log" />
	<input type="hidden" name="task" value="cancel" />
	</form>
	<?php 
        echo '<table class="fc_table">';
        echo "\n" . '<tr><td class="prompt"><strong>' . JText::_('COM_FLEXICONTACT_DATE_TIME') . '</strong></td><td>' . $this->log_data->datetime . '</td></tr>';
        // config_name and config_lang  was only added to the log at version 7.03 so older logs have it blank - better not to show it
        if ($this->log_data->config_name != '') {
            echo "\n" . '<tr><td class="prompt"><strong>' . JText::_('COM_FLEXICONTACT_CONFIG_NAME') . '</strong></td><td>' . $this->log_data->config_name . '</td></tr>';
        }
        if ($this->log_data->config_lang != '') {
            echo "\n" . '<tr><td class="prompt"><strong>' . JText::_('COM_FLEXICONTACT_LANGUAGE') . '</strong></td><td>' . $this->log_data->config_lang . '</td></tr>';
        }
        echo "\n" . '<tr><td class="prompt"><strong>' . JText::_('COM_FLEXICONTACT_NAME') . '</strong></td><td>' . $this->log_data->name . '</td></tr>';
        echo "\n" . '<tr><td class="prompt"><strong>' . JText::_('COM_FLEXICONTACT_EMAIL') . '</strong></td>';
        if ($this->log_data->email != '') {
            $email_link = 'mailto:' . $this->log_data->email . '?Subject=' . $this->log_data->subject;
            echo '<td>' . JHTML::link($email_link, $this->log_data->email, 'target="_blank"') . '</td></tr>';
        } else {
            echo '<td>' . $this->log_data->email . '</td></tr>';
        }
        echo "\n" . '<tr><td class="prompt"><strong>' . JText::_('COM_FLEXICONTACT_SUBJECT') . '</strong></td><td>' . $this->log_data->subject . '</td></tr>';
        // the main message
        echo "\n" . '<tr><td class="prompt" valign="top"><strong>' . JText::_('COM_FLEXICONTACT_OTHER_DATA') . '</strong></td>';
        $message = nl2br($this->log_data->message);
        if (substr($message, 0, 6) == '<br />') {
            $message = substr($message, 6);
        }
        echo "\n" . '<td style="white-space: normal;">' . $message . '</td></tr>';
        // admin_email was only added to the log at version 7.02 so older logs have it blank - better not to show it
        if ($this->log_data->admin_email != '') {
            echo "\n" . '<tr><td class="prompt"><strong>' . JText::_('COM_FLEXICONTACT_V_EMAIL_TO') . '</strong></td><td>' . $this->log_data->admin_email . '</td></tr>';
        }
        echo "\n" . '<tr><td class="prompt"><strong>' . JText::_('COM_FLEXICONTACT_IP_ADDRESS') . '</strong></td><td>' . $this->log_data->ip . '</td></tr>';
        echo "\n" . '<tr><td class="prompt"><strong>' . JText::_('COM_FLEXICONTACT_BROWSER') . '</strong></td><td>' . $this->log_data->browser_string . '</td></tr>';
        echo "\n" . '<tr><td class="prompt"><strong>' . JText::_('COM_FLEXICONTACT_STATUS') . '</strong></td><td>' . $this->_status($this->log_data->status_main) . '</td></tr>';
        echo "\n" . '<tr><td class="prompt"><strong>' . JText::_('COM_FLEXICONTACT_STATUS_COPY') . '</strong></td><td>' . $this->_status($this->log_data->status_copy) . '</td></tr>';
        if ($this->log_data->imported) {
            echo "\n" . '<tr><td colspan="2">' . JText::_('COM_FLEXICONTACT_IMPORTED') . '</td><td></td></tr>';
        }
        echo '</table>';
    }
Exemplo n.º 9
0
 function submitinfo()
 {
     jimport('joomla.mail.helper');
     $app =& JFactory::getApplication();
     $params = JComponentHelper::getParams('com_redevent');
     if (!$params->get('enable_moreinfo', 1)) {
         echo Jtext::_('COM_REDEVENT_MOREINFO_ERROR_DISABLED_BY_ADMIN');
         $app->close(403);
     }
     $xref = JRequest::getInt('xref');
     $email = JRequest::getVar('email');
     $model = $this->getModel('details');
     $details = $model->getDetails();
     if ($xref && $email && JMailHelper::isEmailAddress($email)) {
         $mailer =& JFactory::getMailer();
         $mailer->IsHTML(true);
         $mailer->setSubject(JText::sprintf('COM_REDEVENT_MOREINFO_MAIL_SUBJECT', $details->full_title));
         $mailer->AddAddress($app->getCfg('mailfrom'), $app->getCfg('sitename'));
         $mailer->AddReplyTo(array($email, JRequest::getVar('name')));
         $data = array();
         if ($d = JRequest::getVar('name')) {
             $data[] = array(Jtext::_('COM_REDEVENT_MOREINFO_LABEL_NAME'), $d);
         }
         if ($d = JRequest::getVar('email')) {
             $data[] = array(Jtext::_('COM_REDEVENT_MOREINFO_LABEL_EMAIL'), $d);
         }
         if ($d = JRequest::getVar('company')) {
             $data[] = array(Jtext::_('COM_REDEVENT_MOREINFO_LABEL_COMPANY'), $d);
         }
         if ($d = JRequest::getVar('phonenumber')) {
             $data[] = array(Jtext::_('COM_REDEVENT_MOREINFO_LABEL_PHONENUMBER'), $d);
         }
         if ($d = JRequest::getVar('comments')) {
             $data[] = array(Jtext::_('COM_REDEVENT_MOREINFO_LABEL_COMMENTS'), str_replace("\n", "<br/>", $d));
         }
         $table = '<table>';
         foreach ($data as $d) {
             $table .= '<tr><td>' . $d[0] . '</td><td>' . $d[1] . '</td></tr>';
         }
         $table .= '</table>';
         $link = JRoute::_(JURI::base() . RedeventHelperRoute::getDetailsRoute($details->did, $details->xslug));
         $link = JHTML::link($link, $details->full_title);
         $body = JText::sprintf('COM_REDEVENT_MOREINFO_MAIL_BODY', $link, $table);
         $mailer->setBody($body);
         $mailer->send();
     }
     // confirm sending
     JRequest::setVar('view', 'moreinfo');
     Jrequest::setVar('layout', 'final');
     $this->display();
 }
Exemplo n.º 10
0
 function getPlayerLink($item, $params, $project)
 {
     $flag = "";
     if ($params->get('show_player_flag')) {
         $flag = Countries::getCountryFlag($item->country) . "&nbsp;";
     }
     $text = "<i>" . JoomleagueHelper::formatName(null, $item->firstname, $item->nickname, $item->lastname, $params->get("name_format")) . "</i>";
     if ($params->get('show_player_link')) {
         $link = JoomleagueHelperRoute::getPlayerRoute($params->get('p'), $params->get('team'), $item->slug);
         echo $flag . JHTML::link($link, $text);
     } else {
         echo '<i>' . JText::sprintf('%1$s', $flag . $text) . '</i>';
     }
 }
Exemplo n.º 11
0
function jdGetScanStatus()
{
    require_once JPATH_COMPONENT_ADMINISTRATOR . DS . 'helpers' . DS . 'log.php';
    $objResponse = new xajaxResponse();
    $controller = new JDefenderControllerScan();
    $scanStatus = $controller->scan($doLog = JD_Scan_Helper::isLogging());
    $scanInfo = JD_Vars_Helper::getGroup('jdefender_scan');
    if (empty($scanInfo)) {
        $scanInfo = array();
    }
    unset($scanInfo['status']);
    $progress = 0;
    if (!empty($scanInfo['total'])) {
        $scanned = 0;
        $scanned += @$scanInfo['files'];
        $scanned += @$scanInfo['dirs'];
        $progress = (int) floor($scanned / $scanInfo['total'] * 100);
    }
    $objResponse->assign('scanstatus', 'innerHTML', JText::_('Progress') . ': ' . $progress . '%');
    $objResponse->script('setProgress(' . $progress . ');');
    $objResponse->script('blink("scanstatus", 2);');
    $js = array();
    foreach ($scanInfo as $k => $v) {
        if ($k == 'last_scan_date') {
            continue;
        }
        $titles = JD_Log_Helper::readableLogType($k);
        if ($titles) {
            $js[] = '"' . addslashes(JHTML::link('index.php?option=com_jdefender&controller=log&task=showLog&cid[]=' . $k, $titles->title, 'target="_blank"')) . '" : ' . (int) $v;
        } else {
            $js[] = $k . ': ' . (int) $v;
        }
    }
    $js = '{' . implode(', ', $js) . '}';
    $objResponse->script('onInfoUpdated("' . addslashes($js) . '")');
    // Check scan status.
    if ($scanStatus && is_array($scanStatus) && count($scanStatus) == 2) {
        list($filesystemScanComplete, $optionScanComplete) = $scanStatus;
        if ($filesystemScanComplete && $optionScanComplete) {
            $objResponse->script('onScanComplete()');
        }
    }
    return $objResponse;
}
Exemplo n.º 12
0
 /**
  * Check upgrade / database status
  */
 function check()
 {
     $this->profiles = $this->checkTable('#__wf_profiles');
     if ($this->profiles) {
         $this->profiles = $this->checkTableContents('#__wf_profiles');
     }
     if (!$this->checkComponent()) {
         return $this->install(true);
     }
     // Check Profiles DB
     if (!$this->profiles) {
         return $this->redirect();
     }
     // Check Editor is installed
     if (!$this->checkEditor()) {
         $link = JHTML::link('index.php?option=com_jce&amp;task=repair&amp;type=editor', WFText::_('WF_EDITOR_INSTALL'));
         return $this->redirect(WFText::_('WF_EDITOR_INSTALLED_MANUAL_ERROR') . ' - ' . $link, 'error');
     }
     // Check Editor is enabled
     if (!$this->checkEditorEnabled()) {
         return $this->redirect(WFText::_('WF_EDITOR_ENABLED_ERROR'), 'error');
     }
 }
Exemplo n.º 13
0
function showHelpScreen()
{
	JToolBarHelper::title(JTEXT::_('TOOLBAR_HELP'), 'article.png');
	flexicontact_html::adminForm();
	$link_doc = "http://extensions.lesarbresdesign.info/en/downloads/category/2-flexicontact";
	$link_images = "http://extensions.lesarbresdesign.info/en/flexicontact/captcha-image-packs";
	$link_version = "http://extensions.lesarbresdesign.info/en/version-history/flexicontact";
	$link_rating = "http://extensions.joomla.org/extensions/contacts-and-feedback/contact-forms/9743";
	$link_chrisguk = "http://extensions.joomla.org/extensions/owner/chrisguk";
	$link_LAextensions = "http://extensions.lesarbresdesign.info/";
	?>
	<p style="color:#0B55C4; font-size:15px"><?php echo LA_COMPONENT_NAME.': '.JTEXT::_('HELP_TITLE');?></p>
	<?php echo JText::sprintf('VERSION', LA_COMPONENT_NAME).' '.LA_COMPONENT_VERSION?><br />
	<p><?php echo '<strong>'.JTEXT::_('HELP_CONFIG').'</strong>';?></p>
	<p><?php echo JTEXT::_('HELP_DOC').' '.JHTML::link($link_doc, "www.lesarbresdesign.info", 'target="_blank"');?></p>
	<p><?php echo JTEXT::_('HELP_IMAGES').' '.JHTML::link($link_images, "www.lesarbresdesign.info", 'target="_blank"');?></p>
	<p><?php echo JTEXT::_('HELP_CHECK').' '.JHTML::link($link_version, 'Les Arbres Design - Flexicontact', 'target="_blank"');?></p>
	<p><?php echo JText::sprintf('HELP_RATING', LA_COMPONENT_NAME).' '.JHTML::link($link_rating, 'Joomla! Extensions', 'target="_blank"');?></p>
	<p><?php echo JTEXT::sprintf('HELP_LES_ARBRES', LA_COMPONENT_NAME, JHTML::link($link_chrisguk, 'Joomla! Extensions', 'target="_blank"')).' '.JHTML::link($link_LAextensions, 'Les Arbres Design', 'target="_blank"');?><p>
	<table>
		<tr></tr>
		<tr>
			<td><?php echo JText::sprintf('HELP_FUND_ONE', LA_COMPONENT_NAME);?><br />
				<?php echo JText::_('HELP_FUND_TWO');?>
			</td>
			<td>
				<form action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_blank">
					<input type="hidden" name="cmd" value="_s-xclick">
					<input type="hidden" name="hosted_button_id" value="11095351">
					<input type="image" src="<?php echo JText::_('HELP_DONATE_BUTTON');?>" border="0" name="submit" alt="PayPal - The safer, easier way to pay online.">
					<img alt="" border="0" src="https://www.paypal.com/en_GB/i/scr/pixel.gif" width="1" height="1">
				</form>
			</td>
		</tr>
	</table>
	<?php	
}
Exemplo n.º 14
0
 function prepareAjaxData($checkAutomaticSelected = false)
 {
     // Added for the zone shipment module
     //$vars["zone_qty"] = 0;
     $this->prepareCartData($checkAutomaticSelected);
     $weight_total = 0;
     $weight_subtotal = 0;
     //of course, some may argue that the $this->data->products should be generated in the view.html.php, but
     //
     if (empty($this->data)) {
         $this->data = new stdClass();
     }
     $this->data->products = array();
     $this->data->totalProduct = 0;
     $i = 0;
     //OSP when prices removed needed to format billTotal for AJAX
     if (!class_exists('CurrencyDisplay')) {
         require JPATH_VM_ADMINISTRATOR . DS . 'helpers' . DS . 'currencydisplay.php';
     }
     $currency = CurrencyDisplay::getInstance();
     foreach ($this->products as $priceKey => $product) {
         //$vars["zone_qty"] += $product["quantity"];
         $category_id = $this->getCardCategoryId($product->virtuemart_product_id);
         //Create product URL
         $url = JRoute::_('index.php?option=com_virtuemart&view=productdetails&virtuemart_product_id=' . $product->virtuemart_product_id . '&virtuemart_category_id=' . $category_id, FALSE);
         // @todo Add variants
         $this->data->products[$i]['product_name'] = JHTML::link($url, $product->product_name);
         // Add the variants
         if (!is_numeric($priceKey)) {
             if (!class_exists('VirtueMartModelCustomfields')) {
                 require JPATH_VM_ADMINISTRATOR . DS . 'models' . DS . 'customfields.php';
             }
             //  custom product fields display for cart
             $this->data->products[$i]['product_attributes'] = VirtueMartModelCustomfields::CustomsFieldCartModDisplay($priceKey, $product);
         }
         $this->data->products[$i]['product_sku'] = $product->product_sku;
         //** @todo WEIGHT CALCULATION
         //$weight_subtotal = vmShipmentMethod::get_weight($product["virtuemart_product_id"]) * $product->quantity'];
         //$weight_total += $weight_subtotal;
         // product Price total for ajax cart
         // 			$this->data->products[$i]['prices'] = $this->prices[$priceKey]['subtotal_with_tax'];
         $this->data->products[$i]['pricesUnformatted'] = $this->pricesUnformatted[$priceKey]['subtotal_with_tax'];
         $this->data->products[$i]['prices'] = $currency->priceDisplay($this->pricesUnformatted[$priceKey]['subtotal_with_tax']);
         // other possible option to use for display
         $this->data->products[$i]['subtotal'] = $this->pricesUnformatted[$priceKey]['subtotal'];
         $this->data->products[$i]['subtotal_tax_amount'] = $this->pricesUnformatted[$priceKey]['subtotal_tax_amount'];
         $this->data->products[$i]['subtotal_discount'] = $this->pricesUnformatted[$priceKey]['subtotal_discount'];
         $this->data->products[$i]['subtotal_with_tax'] = $this->pricesUnformatted[$priceKey]['subtotal_with_tax'];
         // UPDATE CART / DELETE FROM CART
         $this->data->products[$i]['quantity'] = $product->quantity;
         $this->data->totalProduct += $product->quantity;
         $i++;
     }
     $this->data->billTotal = $currency->priceDisplay($this->pricesUnformatted['billTotal']);
     $this->data->dataValidated = $this->_dataValidated;
     return $this->data;
 }
Exemplo n.º 15
0
        echo $cellwidth . $show_vertical_separator;
        ?>
">
			<div class="spacer">
				<?php 
        // Product Image
        if ($product->images) {
            echo '<div>';
            echo JHTML::_('link', JRoute::_('index.php?option=com_virtuemart&view=productdetails&virtuemart_product_id=' . $product->virtuemart_product_id . '&virtuemart_category_id=' . $product->virtuemart_category_id), $product->images[0]->displayMediaThumb('class="featuredProductImage" border="0"', false, 'class="modal"'));
            echo '</div>';
        }
        ?>
									
				<div>
					<h3 class="catProductTitle"><?php 
        echo JHTML::link(JRoute::_('index.php?option=com_virtuemart&view=productdetails&virtuemart_product_id=' . $product->virtuemart_product_id . '&virtuemart_category_id=' . $product->virtuemart_category_id, FALSE), $product->product_name, array('title' => $product->product_name));
        ?>
</h3>
					
					<div class="catProductPrice" id="productPrice<?php 
        echo $product->virtuemart_product_id;
        ?>
">
					<?php 
        if (VmConfig::get('show_prices') == '1') {
            if ($product->prices['salesPrice'] <= 0 and VmConfig::get('askprice', 1) and !$product->images[0]->file_is_downloadable) {
                echo JText::_('COM_VIRTUEMART_PRODUCT_ASKPRICE');
            }
            echo $this->currency->createPriceDiv('basePriceWithTax', '', $product->prices);
            echo $this->currency->createPriceDiv('taxAmount', 'TPL_GK_LANG_VM_INC_TAX', $product->prices);
        }
Exemplo n.º 16
0
		</h2>

		<?php 
    //flyer
    echo redEVENTImage::modalimage($this->row->locimage, $this->row->venue);
    echo REOutput::mapicon($this->row, array('class' => 'event-map'));
    ?>

		<dl class="location floattext">
			 <dt class="venue"><?php 
    echo JText::_('COM_REDEVENT_VENUE') . ':';
    ?>
</dt>
				<dd class="venue">
				<?php 
    echo JHTML::link($venuelink, $this->escape($this->row->venue));
    ?>
				<?php 
    if (!empty($this->row->url)) {
        ?>
					&nbsp; - &nbsp;
					<a href="<?php 
        echo $this->row->url;
        ?>
"> <?php 
        echo JText::_('COM_REDEVENT_WEBSITE');
        ?>
</a>
				<?php 
    }
    ?>
Exemplo n.º 17
0
   </div>
		<?php 
} else {
    ?>
			<?php 
    if ($merchant->RatingsContext !== 0 && $merchant->RatingsContext !== 2) {
        ?>
				<div class="alert alert-block">
					<?php 
        echo JTEXT::_('COM_BOOKINGFORCONNECTOR_MERCHANTS_VIEW_MERCHANTDETAILS_RATING_NO_RESULT');
        ?>
					<?php 
        if (($this->item->RatingsContext === 1 || $this->item->RatingsContext === 3) && ($this->item->RatingsType == 0 || $this->item->RatingsType == 2)) {
            ?>
						<?php 
            echo JHTML::link(JRoute::_('index.php?option=com_bookingforconnector&layout=rating&view=merchantdetails&merchantId=' . $this->item->MerchantId . ':' . BFCHelper::getSlug($this->item->Name), true, -1), JTEXT::_('COM_BOOKINGFORCONNECTOR_MERCHANTS_VIEW_MERCHANTDETAILS_RATING_BUTTON_COMMENT'), array('class' => 'btn btn-info'));
            ?>
					<?php 
        }
        ?>
	
				</div>
			<?php 
    }
    ?>
	
		<?php 
}
?>
	
</div>
    if ($this->matchreferees) {
        ?>
            <tr>
                <td colspan="3" >
                    <span class="label"><?php 
        echo JText::_('COM_JOOMLEAGUE_MATCHREPORT_REFEREE');
        ?>
</span>
                    <?php 
        $first = true;
        foreach ($this->matchreferees as $referee) {
            $referee_link = JoomleagueHelperRoute::getRefereeRoute($this->project->id, $referee->id);
            if (!$first) {
                echo ', ';
            }
            $link = JHTML::link($referee_link, JoomleagueHelper::formatName(null, $referee->firstname, $referee->nickname, $referee->lastname, $this->config["name_format"]));
            if ($this->config["show_referee_position"] == 1) {
                $link .= ' (' . $referee->position_name . ')';
            }
            ?>
<span><?php 
            echo $link;
            ?>
</span>
                        <?php 
            $first = false;
        }
        ?>
                </td>
            </tr>
            <tr>
    if ($params->get('show_logo', 0)) {
        ?>
				<?php 
        echo modJLGTeamStatHelper::getLogo($team, $params->get('show_logo', 0));
        ?>
				<?php 
    }
    ?>
			
			</td>
			<td class="team">
				<?php 
    if ($params->get('teamlink', '')) {
        ?>
				<?php 
        echo JHTML::link(modJLGTeamStatHelper::getTeamLink($team, $params, $list['project']), $team->{$teamnametype});
        ?>
				<?php 
    } else {
        ?>
				<?php 
        echo $team->{$nametype};
        ?>
				<?php 
    }
    ?>
			</td>
			<td class="td_c"><?php 
    echo $item->total;
    ?>
</td>
Exemplo n.º 20
0
	<td align="left">
		<?php 
    if ($prow->virtuemart_media_id) {
        ?>
		<span class="cart-images">
						 <?php 
        if (!empty($prow->image)) {
            echo $prow->image->displayMediaThumb('', FALSE);
        }
        ?>
						</span>
		<?php 
    }
    ?>
		<?php 
    echo JHTML::link($prow->url, $prow->product_name) . $prow->customfields;
    ?>

	</td>
	<td align="left"><?php 
    echo $prow->product_sku;
    ?>
</td>
	<td align="center">
		<?php 
    // 					vmdebug('$this->cart->pricesUnformatted[$pkey]',$this->cart->pricesUnformatted[$pkey]['priceBeforeTax']);
    echo $this->currencyDisplay->createPriceDiv('basePrice', '', $this->cart->pricesUnformatted[$pkey], false);
    // 					echo $prow->salesPrice ;
    ?>
	</td>
	<td align="right">
Exemplo n.º 21
0
    ?>
                    </strong>
                    <?php 
    if ($category->childs) {
        ?>
                    <ul class="menu<?php 
        echo $class_sfx;
        ?>
">
                              <?php 
        foreach ($category->childs as $child) {
            $caturl = JRoute::_('index.php?option=com_virtuemart&view=category&virtuemart_category_id=' . $child->virtuemart_category_id);
            $cattext = $child->category_name;
            ?>
                              <li><?php 
            echo JHTML::link($caturl, $cattext);
            ?>
 </li>
                              <?php 
        }
        ?>
                    </ul>
                    <?php 
    }
    ?>
          </li>
          <?php 
}
?>
</ul>
Exemplo n.º 22
0
    function display($tpl = null)
    {
        FCP_Admin::make_title('COM_FLEXICONTACT_LOG');
        JToolBarHelper::deleteList('', 'delete_log');
        JToolBarHelper::custom('stats', 'chart.png', 'chart.png', JText::_('COM_FLEXICONTACT_STATS'), false);
        if ($this->free_log_info != null and $this->free_log_info->count > 0) {
            JToolBarHelper::custom('import', 'upload.png', 'upload.png', JText::_('COM_FLEXICONTACT_IMPORT'), false);
        }
        JToolBarHelper::custom('download', 'download.png', 'download.png', JText::_('COM_FLEXICONTACT_DOWNLOAD'), false);
        // get the order states
        $app = JFactory::getApplication();
        $filter_order = $app->getUserStateFromRequest(LAFC_COMPONENT . '.filter_order', 'filter_order', 'date_time');
        $filter_order_Dir = $app->getUserStateFromRequest(LAFC_COMPONENT . '.filter_order_Dir', 'filter_order_Dir', 'desc');
        $lists['order_Dir'] = $filter_order_Dir;
        $lists['order'] = $filter_order;
        $search = $app->getUserStateFromRequest(LAFC_COMPONENT . '.search', 'search', '', 'string');
        $lists['search'] = JString::strtolower($search);
        // get the current filters
        $filter_date = $app->getUserStateFromRequest(LAFC_COMPONENT . '.filter_date', 'filter_date', LAFC_LOG_LAST_28_DAYS, 'int');
        $filter_config = $app->getUserStateFromRequest(LAFC_COMPONENT . '.filter_config', 'filter_config', 'all', 'string');
        // make the filter lists
        $date_filters = array(LAFC_LOG_ALL => JText::_('COM_FLEXICONTACT_LOG_ALL'), LAFC_LOG_LAST_7_DAYS => JText::_('COM_FLEXICONTACT_LOG_LAST_7_DAYS'), LAFC_LOG_LAST_28_DAYS => JText::_('COM_FLEXICONTACT_LOG_LAST_28_DAYS'), LAFC_LOG_LAST_12_MONTHS => JText::_('COM_FLEXICONTACT_LOG_LAST_12_MONTHS'));
        $lists['date_filters'] = FCP_Common::make_list('filter_date', $filter_date, $date_filters, 0, 'onchange="this.form.task.value=\'log_list\';submitform( );"');
        $lists['config_filters'] = FCP_Common::make_list('filter_config', $filter_config, $this->config_list, ' ', 'onchange="this.form.task.value=\'log_list\';submitform( );"');
        // Joomla 3.0 took away the Javascript checkAll() function. Joomla.checkAll() first appeared in 1.7
        $numrows = count($this->log_list);
        $check_all = 'onclick="Joomla.checkAll(this);"';
        // Show the list
        ?>
	<form action="index.php" method="post" name="adminForm" id="adminForm">
	<input type="hidden" name="option" value="<?php 
        echo LAFC_COMPONENT;
        ?>
" />
	<input type="hidden" name="controller" value="log" />
	<input type="hidden" name="task" value="log_list" />
	<input type="hidden" name="boxchecked" value="0" />
	<input type="hidden" name="view" value="log_list" />
	<input type="hidden" name="filter_order" value="<?php 
        echo $lists['order'];
        ?>
" />
	<input type="hidden" name="filter_order_Dir" value="<?php 
        echo $lists['order_Dir'];
        ?>
" />

	<table>
	<tr>
		<td align="left" width="100%">
			<?php 
        echo ' ' . JText::_('COM_FLEXICONTACT_SEARCH') . ':';
        echo '<input type="text" size="60" name="search" id="search" value="';
        echo $lists['search'];
        echo '" class="text_area" />';
        echo ' <button class="fcp_button" onclick="this.form.task.value=\'log_list\';this.form.submit();">' . JText::_('COM_FLEXICONTACT_GO') . '</button>';
        ?>
		</td>
		<td nowrap="nowrap">
			<?php 
        echo JText::_('COM_FLEXICONTACT_CONFIGURATION') . $lists['config_filters'] . '&nbsp;';
        echo $lists['date_filters'];
        echo '&nbsp;';
        echo '<button class="fcp_button" onclick="' . "\n\t\t\t\t\tthis.form.filter_date.value='" . LAFC_LOG_LAST_28_DAYS . "';\n\t\t\t\t\tthis.form.search.value='';\n\t\t\t\t\tthis.form.filter_config.value='all';\n\t\t\t\t\tthis.form.task.value='log_list';\n\t\t\t\t\tthis.form.submit();" . '">' . JText::_('COM_FLEXICONTACT_RESET') . '</button>';
        ?>
		</td>
	</tr>
	</table>

	<table class="adminlist table table-striped">
	<thead>
	<tr>
		<th width="20"><input type="checkbox" name="toggle" value="" <?php 
        echo $check_all;
        ?>
 /></th>
		<th class="title" nowrap="nowrap">
			<?php 
        echo JHTML::_('grid.sort', 'COM_FLEXICONTACT_DATE_TIME', 'datetime', $lists['order_Dir'], $lists['order']);
        ?>
</th>
		<th class="title" nowrap="nowrap">
			<?php 
        echo JHTML::_('grid.sort', 'COM_FLEXICONTACT_NAME', 'name', $lists['order_Dir'], $lists['order']);
        ?>
</th>
		<th class="title" nowrap="nowrap">
			<?php 
        echo JHTML::_('grid.sort', 'COM_FLEXICONTACT_EMAIL', 'email', $lists['order_Dir'], $lists['order']);
        ?>
</th>
		<th class="title" nowrap="nowrap">
			<?php 
        echo JHTML::_('grid.sort', 'COM_FLEXICONTACT_SUBJECT', 'subject', $lists['order_Dir'], $lists['order']);
        ?>
</th>
		<th class="title" nowrap="nowrap"><?php 
        echo JText::_('COM_FLEXICONTACT_OTHER_DATA');
        ?>
</th>
		<th class="title" nowrap="nowrap"><?php 
        echo JText::_('COM_FLEXICONTACT_STATUS');
        ?>
</th>
	</tr>
	</thead>

	<tfoot>
	<tr>
		<td colspan="15">
			<?php 
        echo $this->pagination->getListFooter();
        ?>
		</td>
	</tr>
	</tfoot>
	
	<tbody>
	<?php 
        $k = 0;
        for ($i = 0; $i < $numrows; $i++) {
            $row = $this->log_list[$i];
            $link = JRoute::_(LAFC_COMPONENT_LINK . '&controller=log&task=log_detail&log_id=' . $row->id);
            $checked = JHTML::_('grid.id', $i, $row->id);
            $date = JHTML::link($link, $row->datetime);
            $name = preg_replace('/[^(a-zA-Z \\x27)]*/', '', $row->name);
            // remove all except a-z, A-Z, and '
            $subject = preg_replace('/[^(a-zA-Z1-9 \\x27)]*/', '', $row->subject);
            $other_data = str_replace('<br />', ' ', $row->short_message);
            //		$other_data = preg_replace('/[^(a-zA-Z1-9 :\x27)]*/','', $other_data);
            $status_main = $this->_status($row->status_main);
            $status_copy = $this->_status($row->status_copy);
            $attachment = $this->_attachment($row->attached_file);
            echo "\n" . '<tr class="row' . $k . '">';
            echo "\n " . '<td align="center">' . $checked . '</td>';
            echo "\n " . '<td nowrap="nowrap">' . $date . '</td>';
            echo "\n " . '<td>' . $name . '</td>';
            if ($row->email != '') {
                $email_link = 'mailto:' . $row->email . '?Subject=' . $subject;
                echo "\n " . '<td>' . JHTML::link($email_link, $row->email, 'target="_blank"') . '</td>';
            } else {
                echo "\n " . '<td>' . $row->email . '</td>';
            }
            echo "\n " . '<td>' . $subject . '</td>';
            echo "\n " . '<td>' . $other_data . '</td>';
            echo "\n " . '<td>' . $status_main . ' ' . $status_copy . ' ' . $attachment . '</td>';
            echo "\n" . '</tr>';
            $k = 1 - $k;
        }
        ?>
	</tbody>
	</table>
	</form>
	<?php 
    }
Exemplo n.º 23
0
<?php

defined('_JEXEC') or die;
$seo = JHTML::link('http://wikipedia.org/wiki/Search_engine_optimization', 'SEO', array('target' => '_blank'));
$download = JHTML::link('http://extensions.joomla.org/component/option,com_mtree/task,viewlink/link_id,4010/Itemid,35/', 'Joomla!', array('target' => '_blank'));
?>

<div class="linkrc">
	<h2 style="text-align:center;">
		<?php 
echo JText::_('FAQ');
?>
	</h2>
	
	<h3><?php 
echo JText::_('FAQ_1');
?>
</h3>
	<div class="linkrc">
		<?php 
echo JText::_('FAQ_1_ANSWER');
?>
	</div>
	
	<h3><?php 
echo JText::_('FAQ_2');
?>
</h3>
	<div class="linkrc">
		<?php 
echo JText::sprintf('FAQ_2_ANSWER', $seo);
    /**
     * Formating front display by roles
     *  for product only !
     */
    public function displayProductCustomfieldFE(&$product, $customfield, $row = '')
    {
        $virtuemart_custom_id = isset($customfield->virtuemart_custom_id) ? $customfield->virtuemart_custom_id : 0;
        $value = $customfield->custom_value;
        $type = $customfield->field_type;
        $is_list = isset($customfield->is_list) ? $customfield->is_list : 0;
        $price = isset($customfield->custom_price) ? $customfield->custom_price : 0;
        $is_cart = isset($customfield->is_cart) ? $customfield->is_cart : 0;
        //vmdebug('displayProductCustomfieldFE and here is something wrong ',$customfield);
        JLoader::register('CurrencyDisplay', JPATH_VM_ADMINISTRATOR . '/helpers/currencydisplay.php');
        $currency = CurrencyDisplay::getInstance();
        if ($is_list > 0) {
            $values = explode(';', $value);
            if ($is_cart != 0) {
                $options = array();
                foreach ($values as $key => $val) {
                    $options[] = array('value' => $val, 'text' => $val);
                }
                // J3 use chosen vmJsApi::chosenDropDowns();
                return JHTML::_('select.genericlist', $options, 'field[' . $row . '][custom_value]', NULL, 'value', 'text', FALSE, TRUE);
            } else {
                $html = '';
                $html .= '<div id="custom_' . $virtuemart_custom_id . '_' . $value . '" >' . $value . '</div>';
                return $html;
            }
        } else {
            if ($price > 0) {
                $price = $currency->priceDisplay((double) $price);
            }
            switch ($type) {
                case 'A':
                    $options = array();
                    $session = JFactory::getSession();
                    $virtuemart_category_id = $session->get('vmlastvisitedcategoryid', 0, 'vm');
                    $productModel = VmModel::getModel('product');
                    //parseCustomParams
                    VirtueMartModelCustomfields::bindParameterableByFieldType($customfield);
                    //Todo preselection as dropdown of children
                    //Note by Max Milbers: This is not necessary, in this case it is better to unpublish the parent and to give the child which should be preselected a category
                    //Or it is withParent, in that case there exists the case, that a parent should be used as a kind of mini category and not be orderable.
                    //There exists already other customs and in special plugins which wanna disable or change the add to cart button.
                    //I suggest that we manipulate the button with a message "choose a variant first"
                    //if(!isset($customfield->pre_selected)) $customfield->pre_selected = 0;
                    $selected = JRequest::getVar('virtuemart_product_id', 0);
                    if (is_array($selected)) {
                        $selected = $selected[0];
                    }
                    $selected = (int) $selected;
                    $html = '';
                    $uncatChildren = $productModel->getUncategorizedChildren($customfield->withParent);
                    if (empty($uncatChildren)) {
                        return $html;
                        break;
                    }
                    foreach ($uncatChildren as $k => $child) {
                        $options[] = array('value' => JRoute::_('index.php?option=com_virtuemart&view=productdetails&virtuemart_category_id=' . $virtuemart_category_id . '&virtuemart_product_id=' . $child['virtuemart_product_id']), 'text' => $child['product_name']);
                    }
                    $html .= JHTML::_('select.genericlist', $options, 'field[' . $row . '][custom_value]', 'onchange="window.top.location.href=this.options[this.selectedIndex].value" size="1" class="inputbox"', "value", "text", JRoute::_('index.php?option=com_virtuemart&view=productdetails&virtuemart_category_id=' . $virtuemart_category_id . '&virtuemart_product_id=' . $selected, 'cf' . $row . '-' . $selected));
                    //vmdebug('$customfield',$customfield);
                    if ($customfield->parentOrderable == 0 and $product->product_parent_id == 0) {
                        $product->orderable = FALSE;
                    }
                    return $html;
                    break;
                    /* variants*/
                /* variants*/
                case 'V':
                    if ($price == 0) {
                        $price = JText::_('COM_VIRTUEMART_CART_PRICE_FREE');
                    }
                    /* Loads the product price details */
                    return '<input type="text" value="' . JText::_($value) . '" name="field[' . $row . '][custom_value]" /> ' . JText::_('COM_VIRTUEMART_CART_PRICE') . $price . ' ';
                    break;
                    /*Date variant*/
                /*Date variant*/
                case 'D':
                    return '<span class="product_custom_date">' . vmJsApi::date($value, 'LC1', TRUE) . '</span>';
                    //vmJsApi::jDate($field->custom_value, 'field['.$row.'][custom_value]','field_'.$row.'_customvalue').$priceInput;
                    break;
                    /* text area or editor No JText, only displayed in BE */
                /* text area or editor No JText, only displayed in BE */
                case 'X':
                case 'Y':
                    return $value;
                    break;
                    /* string or integer */
                /* string or integer */
                case 'S':
                case 'I':
                    return JText::_($value);
                    break;
                    /* bool */
                /* bool */
                case 'B':
                    if ($value == 0) {
                        return JText::_('COM_VIRTUEMART_NO');
                    }
                    return JText::_('COM_VIRTUEMART_YES');
                    break;
                    /* parent */
                /* parent */
                case 'P':
                    return '<span class="product_custom_parent">' . JText::_($value) . '</span>';
                    break;
                    /* product kit(bundle) */
                /* product kit(bundle) */
                case 'K':
                    $pModel = VmModel::getModel('product');
                    $related = $pModel->getProduct((int) $value, TRUE, TRUE, TRUE, 1, FALSE);
                    if (!$related) {
                        vmError('related product is missing, maybe unpublished');
                        return false;
                    }
                    $param = json_decode($customfield->custom_param);
                    if (empty($param->is_hidden)) {
                        $thumb = '';
                        if (!empty($related->virtuemart_media_id[0])) {
                            $thumb = $this->displayCustomMedia($related->virtuemart_media_id[0]) . ' ';
                        } else {
                            $thumb = $this->displayCustomMedia(0) . ' ';
                        }
                        return '<span class="span2">' . $thumb . '</span>
							<span class="span8">' . $related->product_name . '</span></span>
							<input type="hidden" name="virtuemart_product_id[]" value="' . $related->virtuemart_product_id . '"/>
							<input type="text" class="quantity-input span2" name="quantity[]" value="1"/>
							';
                    } else {
                        return '<input type="hidden" name="virtuemart_product_id[]" value="' . $related->virtuemart_product_id . '"/>
								<input type="hidden" class="quantity-input" name="quantity[]" value="1"/>';
                    }
                    break;
                    /* related */
                /* related */
                case 'R':
                    $pModel = VmModel::getModel('product');
                    $related = $pModel->getProduct((int) $value, TRUE, TRUE, TRUE, 1, FALSE);
                    if (!$related) {
                        vmError('related product is missing, maybe unpublished');
                        return false;
                    }
                    $thumb = '';
                    if (!empty($related->virtuemart_media_id[0])) {
                        $thumb = $this->displayCustomMedia($related->virtuemart_media_id[0]) . ' ';
                    } else {
                        $thumb = $this->displayCustomMedia(0) . ' ';
                    }
                    return JHTML::link(JRoute::_('index.php?option=com_virtuemart&view=productdetails&virtuemart_product_id=' . $related->virtuemart_product_id . '&virtuemart_category_id=' . $related->virtuemart_category_id, FALSE), $thumb . $related->product_name, array('title' => $related->product_name));
                    break;
                    /* image */
                /* image */
                case 'M':
                    return $this->displayCustomMedia($value);
                    break;
                    /* categorie */
                /* categorie */
                case 'Z':
                    $q = 'SELECT * FROM `#__virtuemart_categories_' . VMLANG . '` as l JOIN `#__virtuemart_categories` AS c using (`virtuemart_category_id`) WHERE `published`=1 AND l.`virtuemart_category_id`= "' . (int) $value . '" ';
                    $this->_db->setQuery($q);
                    if ($category = $this->_db->loadObject()) {
                        $q = 'SELECT `virtuemart_media_id` FROM `#__virtuemart_category_medias`WHERE `virtuemart_category_id`= "' . $category->virtuemart_category_id . '" ';
                        $this->_db->setQuery($q);
                        $thumb = '';
                        if ($media_id = $this->_db->loadResult()) {
                            $thumb = $this->displayCustomMedia($media_id, 'category');
                        }
                        return JHTML::link(JRoute::_('index.php?option=com_virtuemart&view=category&virtuemart_category_id=' . $category->virtuemart_category_id, 'cf' . $row . '-' . (int) $value), $thumb . ' ' . $category->category_name, array('title' => $category->category_name));
                    } else {
                        return '';
                    }
                    /* Child Group list
                     * this have no direct display , used for stockable product
                     */
                /* Child Group list
                 * this have no direct display , used for stockable product
                 */
                case 'G':
                    return '';
                    //'<input type="text" value="'.JText::_($value).'" name="field['.$row.'][custom_value]" /> '.JText::_('COM_VIRTUEMART_CART_PRICE').' : '.$price .' ';
                    break;
                    break;
            }
        }
    }
Exemplo n.º 25
0
            echo $product->stock->stock_level;
            ?>
" title="<?php 
            echo $product->stock->stock_tip;
            ?>
"></span> <span class="stock-level"><?php 
            echo JText::_('COM_VIRTUEMART_STOCK_LEVEL_DISPLAY_TITLE_TIP');
            ?>
</span> </div>
					<?php 
        }
        ?>
					<p>
						<?php 
        // Product Details Button
        echo JHTML::link($product->link, JText::_('COM_VIRTUEMART_PRODUCT_DETAILS'), array('title' => $product->product_name, 'class' => 'product-details'));
        ?>
					</p>
				</div>
				<div class="clear"></div>
			</div>
			<!-- end of spacer --> 
		</div>
		<!-- end of product -->
		<?php 
        // Do we need to close the current row now?
        if ($iBrowseCol == $BrowseProducts_per_row || $iBrowseProduct == $BrowseTotalProducts) {
            ?>
		<div class="clear"></div>
	</div>
	<!-- end of row -->
Exemplo n.º 26
0
 /**
  * Builds up an html link using the various parts supplied
  *
  * @param $view a JView object, to be able to escape output text
  * @param $linkData an array of key/value pairs to build up the target links
  * @param $elementData an array holding element data : title, class, rel
  * @param $modal boolean, if true, required stuff to make the link open in modal box is added
  * @param $hasTip boolean, if true, required stuff to turn elementData['title'] into a tooltip is added
  * @param $extra an array holding key/value pairs, will be added as raw attributes to the link
  */
 public static function makeLink($view, $linkData, $elementData, $modal = false, $modalOptions = array(), $hasTip = false, $extra = array())
 {
     // calculate target link
     if ($modal) {
         $linkData['tmpl'] = 'component';
     }
     $url = Sh404sefHelperGeneral::buildUrl($linkData);
     $url = JRoute::_($url);
     // calculate title
     $title = empty($elementData['title']) ? '' : $elementData['title'];
     $title = is_null($view) ? $title : $view->escape($title);
     $attribs = array();
     // calculate class
     $class = empty($elementData['class']) ? '' : $elementData['class'];
     if ($hasTip) {
         $class .= ' ' . $hasTip;
     }
     // store title in attributes array
     if (!empty($title)) {
         $attribs['title'] = $title;
     }
     // store in attributes array
     if (!empty($class)) {
         $attribs['class'] = $class;
     }
     // calculate modal information
     $rel = empty($elementData['rel']) || is_null($view) ? '' : $view->escape($elementData['rel']);
     if ($modal) {
         $modalOptionsString = Sh404sefHelperHtml::makeSqueezeboxOptions($modalOptions);
         $rel .= ' {handler: \'iframe\'' . (empty($modalOptionsString) ? '' : ', ' . $modalOptionsString) . '}';
     }
     // store in attributes array
     if (!empty($rel)) {
         $attribs['rel'] = $rel;
     }
     // any custom attibutes ?
     if (!empty($extra)) {
         foreach ($extra as $key => $value) {
             $attribs[$key] = $value;
         }
     }
     // finish link
     $anchor = empty($elementData['anchor']) ? $title : $elementData['anchor'];
     return JHTML::link($url, $anchor, $attribs);
 }
                echo JText::_('COM_JOOMLEAGUE_TEAMINFO_INFO');
                ?>
</span>
		<span class="clubinfo_listing_value"> <?php 
                echo $this->team->info;
                ?>
</span>
	</div>
			<?php 
            }
            if ($this->team->website) {
                ?>
	<div class="jl_parentContainer">
		<span class="clubinfo_listing_item"> <?php 
                echo JText::_('COM_JOOMLEAGUE_TEAMINFO_TEAM_SITE');
                ?>
</span>
		<span class="clubinfo_listing_value"> <?php 
                echo JHTML::link($this->team->team_website, $this->team->team_website, array("target" => "_blank"));
                ?>
</span>
	</div>
			<?php 
            }
        }
        ?>
	</div>
	<br />
	<?php 
    }
}
    ?>
							</td>
							<td class="center">&nbsp;-&nbsp;</td>
							<td class="center"><?php 
    $date2 = JoomleagueHelper::convertDate($row->round_date_last, 1);
    $append = '';
    if ($date2 == '00-00-0000' || $date2 == '') {
        $append = ' style="background-color:#FFCCCC;"';
    }
    echo JHTML::calendar($date2, 'round_date_last' . $row->id, 'round_date_last' . $row->id, '%d-%m-%Y', 'size="10" ' . $append . 'tabindex="3" ' . 'class="center" ' . 'onchange="document.getElementById(\'cb' . $i . '\').checked=true"');
    ?>
</td>
							<td class="center" class="nowrap"><?php 
    $link2Title = JText::_('COM_JOOMLEAGUE_ADMIN_ROUNDS_EDIT_MATCHES_LINK');
    $link2Params = "title='{$link2Title}'";
    echo JHTML::link($link2, $link2Title, $link2Params);
    ?>
</td>
							<td class="center" class="nowrap"><?php 
    if ($row->countUnPublished == 0 && $row->countMatches > 0) {
        $imageTitle = JText::sprintf('COM_JOOMLEAGUE_ADMIN_ROUNDS_ALL_PUBLISHED', $row->countMatches);
        $imageFile = 'administrator/components/com_joomleague/assets/images/ok.png';
        $imageParams = "title='{$imageTitle}'";
        echo JHTML::image($imageFile, $imageTitle, $imageParams);
    } else {
        if ($row->countMatches == 0) {
            $imageTitle = JText::_('COM_JOOMLEAGUE_ADMIN_ROUNDS_ANY_MATCHES');
        } else {
            $imageTitle = JText::sprintf('COM_JOOMLEAGUE_ADMIN_ROUNDS_PUBLISHED_NR', $row->countUnPublished);
        }
        $imageFile = 'administrator/components/com_joomleague/assets/images/error.png';
 /**
  * used in form row template
  * TODO: move to own template file
  * 
  * @param int $i
  * @param object $match
  * @param boolean $backend
  */
 public function editPartResults($i, $match, $backend = false)
 {
     $link = "javascript:void(0)";
     $params = array("onclick" => "switchMenu('part" . $match->id . "')");
     $imgTitle = JText::_('COM_JOOMLEAGUE_ADMIN_EDIT_MATRIX_ROUNDS_PART_RESULT');
     $desc = JHTML::image(JURI::root() . "media/com_joomleague/jl_images/sort01.gif", $imgTitle, array("border" => 0, "title" => $imgTitle));
     echo JHTML::link($link, $desc, $params);
     echo '<span id="part' . $match->id . '" style="display:none">';
     echo '<br />';
     $partresults1 = explode(";", $match->team1_result_split);
     $partresults2 = explode(";", $match->team2_result_split);
     for ($x = 0; $x < $this->project->game_parts; $x++) {
         echo $x + 1 . ".:";
         echo '<input type="text" style="font-size:9px;" name="team1_result_split';
         echo !is_null($i) ? $match->id : '';
         echo '[]" value="';
         echo isset($partresults1[$x]) ? $partresults1[$x] : '';
         echo '" size="2" tabindex="1" class="inputbox"';
         if (!is_null($i)) {
             echo ' onchange="';
             if ($backend) {
                 echo 'document.adminForm.cb' . $i . '.checked=true; isChecked(this.checked);';
             } else {
                 echo '$(\'cb' . $i . '\').checked=true;';
             }
             echo '"';
         }
         echo ' />';
         echo ':';
         echo '<input type="text" style="font-size:9px;"';
         echo ' name="team2_result_split';
         echo !is_null($i) ? $match->id : '';
         echo '[]" value="';
         echo isset($partresults2[$x]) ? $partresults2[$x] : '';
         echo '" size="2" tabindex="1" class="inputbox" ';
         if (!is_null($i)) {
             echo 'onchange="';
             if ($backend) {
                 echo 'document.adminForm.cb' . $i . '.checked=true; isChecked(this.checked);';
             } else {
                 echo '$(\'cb' . $i . '\').checked=true;';
             }
             echo '"';
         }
         echo '/>';
         if ($x < $this->project->game_parts) {
             echo '<br />';
         }
     }
     if ($this->project->allow_add_time) {
         if ($match->match_result_type > 0) {
             echo JText::_('COM_JOOMLEAGUE_RESULTS_OVERTIME') . ':';
             echo '<input type="text" style="font-size:9px;"';
             echo ' name="team1_result_ot' . $match->id . '"';
             echo ' value="';
             echo isset($match->team1_result_ot) ? '' . $match->team1_result_ot : '';
             echo '"';
             echo ' size="2" tabindex="1" class="inputbox" onchange="$(\'cb' . $i . '\').checked=true;" />';
             echo ':';
             echo '<input type="text" style="font-size:9px;"';
             echo ' name="team2_result_ot' . $match->id . '"';
             echo ' value="';
             echo isset($match->team2_result_ot) ? '' . $match->team2_result_ot : '';
             echo '"';
             echo ' size="2" tabindex="1" class="inputbox" onchange="$(\'cb' . $i . '\').checked=true;" />';
         }
         if ($match->match_result_type == 2) {
             echo '<br />';
             echo JText::_('COM_JOOMLEAGUE_RESULTS_SHOOTOUT') . ':';
             echo '<input type="text" style="font-size:9px;"';
             echo ' name="team1_result_so' . $match->id . '"';
             echo ' value="';
             echo isset($match->team1_result_so) ? '' . $match->team1_result_so : '';
             echo '"';
             echo ' size="2" tabindex="1" class="inputbox" onchange="$(\'cb' . $i . '\').checked=true;" />';
             echo ':';
             echo '<input type="text" style="font-size:9px;"';
             echo ' name="team2_result_so' . $match->id . '"';
             echo ' value="';
             echo isset($match->team2_result_so) ? '' . $match->team2_result_so : '';
             echo '"';
             echo ' size="2" tabindex="1" class="inputbox" onchange="$(\'cb' . $i . '\').checked=true;" />';
         }
     }
     echo "</span>";
 }
</td>
		<td class="vs"><?php 
echo JText::_("COM_JOOMLEAGUE_NEXTMATCH_VS");
?>
</td>
		<td class="team"><?php 
if (!is_null($this->teams)) {
    echo $this->teams[1]->name;
} else {
    echo JText::_("COM_JOOMLEAGUE_NEXTMATCH_UNKNOWNTEAM");
}
?>
</td>
	</tr>
</table>

	<?php 
$report_link = JoomleagueHelperRoute::getMatchReportRoute($this->project->id, $this->match->id);
if (isset($this->match->team1_result) && isset($this->match->team2_result)) {
    ?>
			<div class="notice">
			<?php 
    $text = JText::_("COM_JOOMLEAGUE_NEXTMATCH_ALREADYPLAYED");
    echo JHTML::link($report_link, $text);
    ?>
			</div>
			<?php 
}
?>
                
<br />