/** * Execute and display a template script. * * @param string $tpl The name of the template file to parse; automatically searches through the template paths. * * @return mixed A string if successful, otherwise a JError object. */ function display($tpl = null) { // Get config parameters $this->_document = JFactory::getDocument(); $this->_config = JSNConfigHelper::get(); // Initialize toolbar JSNMobilizeHelper::initToolbar('JSN_MOBILIZE_PAGE_CONFIGURATION_TITLE', 'mobilize-config', false); // Get messages $msgs = ''; if (!$this->_config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('CONFIGURATION'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } // Assign variables for rendering $this->assignRef('msgs', $msgs); // Load the submenu. $input = JFactory::getApplication()->input; JSNMobilizeHelper::addSubmenu($input->get('view', 'configuration')); if (!empty($_GET['g']) && $_GET['g'] == 'data') { echo JSNHtmlAsset::loadScript('jsn/data', array('language' => array('JSN_EXTFW_GENERAL_CLOSE' => JText::_('JSN_EXTFW_GENERAL_CLOSE'))), true); } // Load assets JSNMobilizeHelper::loadAssets(); // Display the template parent::display($tpl); }
/** * Display method * * @param string $tpl The name of the template file to parse; automatically searches through the template paths. * * @return void */ public function display($tpl = null) { // Get config parameters $config = JSNConfigHelper::get(); // Set the toolbar JToolbarHelper::title(JText::_('JSN_EASYSLIDER_CONFIGURATION_SETTING')); // Add toolbar menu JSNEasySliderHelper::addToolbarMenu(); // Set the submenu JSNEasySliderHelper::addSubmenu('maintenance'); // Get messages $msgs = ''; if (!$config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('CONFIGURATION'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } // Assign variables for rendering $this->msgs = $msgs; if (!empty($_GET['g']) && $_GET['g'] == 'data') { echo JSNHtmlAsset::loadScript('jsn/data', array('language' => array('JSN_EXTFW_GENERAL_CLOSE' => JText::_('JSN_EXTFW_GENERAL_CLOSE'))), true); } // Add assets JSNEasySliderHelper::addAssets(); $this->_addAssets(); // Display the template parent::display($tpl); }
/** * Execute and display a template script. * * @param string $tpl The name of the template file to parse; automatically searches through the template paths. * * @return mixed A string if successful, otherwise a JError object. * * @see fetch() * @since 11.1 */ public function display($tpl = null) { // Get input object $input = JFactory::getApplication()->input; $this->isPrint = $input->getString('print', 'false'); $this->_form = $this->get('Form'); $this->_item = $this->get('Item'); $this->_infoForm = $this->get('InfoForm'); $dataContentForm = $this->get('FormPages'); $this->nextAndPreviousForm = $this->get('NextAndPreviousForm'); $this->_formPages = $dataContentForm; $this->_document = JFactory::getDocument(); $this->_document->addScriptDeclaration("var dataId = {$this->_item->submission_id}"); $this->_dataSubmission = $this->get('DataSubmission'); $this->_dataFields = $this->get('DataFields'); $config = JSNConfigHelper::get(); // Get messages $msgs = ''; if (!$config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('SUBMISSION'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } // Hide main menu $input->set('hidemainmenu', true); // Initialize toolbar $this->initToolbar(); // Assign variables for rendering $this->assignRef('msgs', $msgs); // Display the template parent::display($tpl); // Load assets JSNUniformHelper::addAssets(); $this->addAssets(); }
/** * Execute and display a template script. * * @param string $tpl The name of the template file to parse; automatically searches through the template paths. * * @return mixed A string if successful, otherwise an Exception object. */ function display($tpl = null) { // Get config parameters $config = JSNConfigHelper::get(); $session = JFactory::getSession(); $objJSNEasySliderSliders = new JSNEasySliderSliders(); $totalSliders = $objJSNEasySliderSliders->countSilderItems(); $layout = $this->getLayout(); $this->totalSliders = $totalSliders; /*Check if it is FREE edition then show warning message to alert that FREE edition only allows create maximum of 3 sliders*/ $this->edition = defined('JSN_EASYSLIDER_EDITION') ? JSN_EASYSLIDER_EDITION : "free"; if (strtolower($this->edition) == 'free') { if ($totalSliders !== false && $totalSliders >= 3) { if ($layout == 'default') { JFactory::getApplication()->enqueueMessage(JText::_('JSN_EASYSLIDER_YOU_HAVE_REACHED_THE_LIMITATION_OF_3_SLIDERS_IN_FREE_EDITION'), 'warning'); } } } if ($session->has('JSN_EASYSLIDER_BACKUP_OLD_DATA_PATH') && (string) $session->get('JSN_EASYSLIDER_BACKUP_OLD_DATA_PATH') != '') { JFactory::getApplication()->enqueueMessage('The data backup file of version 1.x.x has been created from the update process. You can download it <a href="' . JUri::root() . str_replace(JPATH_ROOT . '/', '', (string) $session->get('JSN_EASYSLIDER_BACKUP_OLD_DATA_PATH')) . '"><strong>here<strong></a>', 'notice'); } // Set the toolbar JToolbarHelper::title(JText::_('JSN_EASYSLIDER_SLIDERS')); // Add toolbar menu JToolbarHelper::addNew('slider.add', 'JSN_EASYSLIDER_CREATE_NEW'); JToolbarHelper::editList('slider.edit', 'JTOOLBAR_EDIT'); JToolbarHelper::custom('sliders.duplicate', 'copy.png', 'copy_f2.png', 'JTOOLBAR_DUPLICATE', true); JToolbarHelper::divider(); JToolbarHelper::publish('sliders.publish'); JToolbarHelper::unpublish('sliders.unpublish'); JToolbarHelper::divider(); JToolbarHelper::deleteList('JSN_EASYSLIDER_CONFIRM_DELETE', 'sliders.delete', 'JTOOLBAR_DELETE'); // JToolbarHelper::preferences(); // JToolbarHelper::help(); JToolbarHelper::custom('', ' jsnes-import fa fa-download', ' jsnes-import fa fa-download', 'JSN_EASYSLIDER_IMPORT'); JToolbarHelper::custom('', ' jsnes-export fa fa-upload', ' jsnes-export fa fa-upload', 'JSN_EASYSLIDER_EXPORT'); JToolbarHelper::divider(); JSNEasySliderHelper::addToolbarMenu(); // Set the submenu // JSNEasySliderHelper::addSubmenu('sliders'); // Get messages $msgs = ''; if (!$config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('SLIDERS'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } $this->sliders = $objJSNEasySliderSliders->getSlidersWithoutState(); // Assign variables for rendering $this->msgs = $msgs; $this->objJSNEasySliderSliders = $objJSNEasySliderSliders; // Add assets JSNEasySliderHelper::addAssets(); $this->_addAssets(); // Display the template parent::display($tpl); }
/** * Method for display page. * * @param boolean $tpl The name of the template file to parse; automatically searches through the template paths. * * @return mixed A string if successful, otherwise a JError object. */ public function display($tpl = null) { // Get config parameters $config = JSNConfigHelper::get(); // Set toolbar title JToolBarHelper::title(JText::_('JSN_MOBILIZE_PAGE_UPDATE_TITLE')); // Load assets JSNMobilizeHelper::loadAssets(); // Get messages $msgs = $config->get('disable_all_messages') ? '' : (count($msgs = JSNUtilsMessage::getList('EDIT')) ? JSNUtilsMessage::showMessages($msgs) : ''); // Assign variables for rendering $this->assignRef('msgs', $msgs); // Display the template parent::display($tpl); }
/** * Display method * * @param string $tpl The name of the template file to parse; automatically searches through the template paths. * * @return void */ public function display($tpl = null) { // Get config parameters $config = JSNConfigHelper::get(); $this->_document = JFactory::getDocument(); JHtmlBehavior::framework(); // Set the toolbar JToolBarHelper::title(JText::_('JSN_IMAGESHOW') . ': ' . JText::_('MAINTENANCE_CONFIGURATION_AND_MAINTENANCE'), 'maintenance'); // Get messages $msgs = ''; if (!$config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('CONFIGURATION_AND_MAINTENANCE'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } // Assign variables for rendering $this->assignRef('msgs', $msgs); $this->_addAssets(); $this->addToolbar(); // Type of screen $type = JRequest::getWord('type', 'backup'); $themeName = JRequest::getWord('theme_name'); $sourceType = JRequest::getString('source_type'); switch ($type) { case 'themeparameters': $this->addTemplatePath(JPATH_PLUGINS . DS . 'jsnimageshow' . DS . $themeName . DS . 'views' . DS . 'maintenance' . DS . 'tmpl'); echo $this->loadTemplate('theme_config'); break; case 'profileparameters': $this->addTemplatePath(JPATH_PLUGINS . DS . 'jsnimageshow' . DS . $sourceType . DS . 'views' . DS . 'maintenance' . DS . 'tmpl'); echo $this->loadTemplate('source_config'); break; case 'editprofile': $sourceID = JRequest::getInt('external_source_id'); $countShowlist = JRequest::getInt('count_showlist'); $imageSource = JSNISFactory::getSource($sourceType, 'external'); $imageSource->_source['sourceTable']->load($sourceID); $this->assignRef('sourceInfo', $imageSource->_source['sourceTable']); $this->assignRef('countShowlist', $countShowlist); $this->addTemplatePath(JPATH_PLUGINS . DS . 'jsnimageshow' . DS . 'source' . $sourceType . DS . 'views' . DS . 'maintenance' . DS . 'tmpl'); echo $this->loadTemplate('edit_source_profile'); break; default: // Display the template parent::display($tpl); break; } }
/** * Execute and display a template script. * * @param string $tpl The name of the template file to parse; automatically searches through the template paths. * * @return mixed A string if successful, otherwise a JError object. * * @see fetch() * @since 11.1 */ function display($tpl = null) { $config = JSNConfigHelper::get(); // Get messages $msgs = ''; if (!$config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('LAUNCHPAD'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } $presentationMethods = array('0' => array('value' => '', 'text' => '- ' . JText::_('JSN_UNIFORM_LAUNCHPAD_SELECT_PRESENTATION_METHOD') . ' -'), '1' => array('value' => 'menu', 'text' => JText::_('JSN_UNIFORM_LAUNCHPAD_VIA_MENU_ITEM_COMPONENT')), '2' => array('value' => 'module', 'text' => JText::_('JSN_UNIFORM_LAUNCHPAD_IN_MODULE_POSITION_MODULE')), '3' => array('value' => 'plugin', 'text' => JText::_('JSN_UNIFORM_LAUNCHPAD_INSIDE_ARTICLE_CONTENT_PLUGIN'))); $this->presentationMethods = JHTML::_('select.genericList', $presentationMethods, 'presentation_method', 'disabled="disabled"' . '', 'value', 'text', ""); // Assign variables for rendering $this->assignRef('msgs', $msgs); $this->addToolbar(); parent::display($tpl); $this->_addAssets(); }
/** * Display method * * @return void */ function display($tpl = null) { // Get config parameters $config = JSNConfigHelper::get(); // Add assets $this->_document = JFactory::getDocument(); // Get messages $msgs = ''; if (!$config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('CONFIGURATION'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } // Assign variables for rendering $this->assignRef('msgs', $msgs); $this->_addAssets(); $this->addToolbar(); // Display the template parent::display($tpl); }
/** * Display method * * @param string $tpl The name of the template file to parse; automatically searches through the template paths. * * @return void */ public function display($tpl = null) { // Set toolbar title JToolBarHelper::title(JText::_('JSN_UNIFORM_HELP_HELP_AND_SUPPORT')); // Get config $config = JSNConfigHelper::get(); // Get messages $msgs = ''; if (!$config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('HELP'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } // Load assets JSNUniformHelper::addAssets(); // Assign variables for rendering $this->assignRef('msgs', $msgs); // Display the template parent::display($tpl); }
/** * Execute and display a template script. * * @param string $tpl The name of the template file to parse; automatically searches through the template paths. * * @return mixed A string if successful, otherwise a JError object. * * @see fetch() * @since 11.1 */ function display($tpl = null) { // Get config parameters $config = JSNConfigHelper::get(); // Set the toolbar JToolBarHelper::title(JText::_('JSN_UNIFORM_UPGRADE_PRODUCT')); // Load assets JSNUniformHelper::addAssets(); // Get messages $msgs = ''; if (!$config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('CONFIGURATION'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } // Assign variables for rendering $this->assignRef('msgs', $msgs); // Display the template parent::display($tpl); }
/** * Method for display page. * * @param boolean $tpl The name of the template file to parse; automatically searches through the template paths. * * @return mixed A string if successful, otherwise an Exception object. */ function display($tpl = null) { try { $this->state = $this->get('State'); $this->slider = $this->get('Item'); $this->form = $this->get('Form'); } catch (Exception $e) { throw $e; } $config = JSNConfigHelper::get(); // Get input object $input = JFactory::getApplication()->input; if (empty($this->slider->slider_id)) { $objJSNEasySliderSliders = new JSNEasySliderSliders(); $totalSliders = $objJSNEasySliderSliders->countSilderItems(); /*Check if it is FREE edition then show warning message to alert that FREE edition only allows create maximum of 3 sliders*/ $edition = defined('JSN_EASYSLIDER_EDITION') ? JSN_EASYSLIDER_EDITION : "free"; if (strtolower($edition) == 'free') { if ($totalSliders !== false && $totalSliders >= 3) { JFactory::getApplication()->redirect('index.php?option=com_easyslider&view=sliders'); return false; } } } // Setup toolbar $input->set('hidemainmenu', true); // Get messages $msgs = ''; if (!$config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('SLIDER'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } // Assign variables for rendering $this->assignRef('msgs', $msgs); // Set the toolbar JToolBarHelper::title(JText::_('JSN_EASYSLIDER_EDIT_PRODUCT')); // Add assets JSNEasySliderHelper::addAssets(); $this->objUtils = new JSNEasySliderUtils(); // Display the template parent::display($tpl); }
/** * Display method * * @return void */ function display($tpl = null) { // Get config parameters $config = JSNConfigHelper::get(); // Set the toolbar JToolBarHelper::title(JText::_('JSN_SAMPLE_UPDATE_PRODUCT')); // Add assets $this->_document = JFactory::getDocument(); // Get messages $msgs = ''; if (!$config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('CONFIGURATION'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } $this->assignRef('msgs', $msgs); $this->_addAssets(); $this->addToolbar(); // Display the template parent::display($tpl); }
/** * Execute and display a template script. * * @param string $tpl The name of the template file to parse; automatically searches through the template paths. * * @return mixed A string if successful, otherwise a JError object. * * @see fetch() * @since 11.1 */ function display($tpl = null) { $this->_document = JFactory::getDocument(); $this->_state = $this->get('State'); $this->_formId = 0; if ($this->_state->get('filter.filter_form_id') != 0) { $this->_items = $this->get('Items'); $this->_pagination = $this->get('Pagination'); $this->_viewField = $this->getViewField(); $this->_formId = $this->_state->get('filter.filter_form_id'); $edition = defined('JSN_UNIFORM_EDITION') ? strtolower(JSN_UNIFORM_EDITION) : "free"; if ($edition == "free") { $this->_countSubmission = $this->get('CountSubmission'); $countSubmission = 300 - $this->_countSubmission > 0 ? 300 - $this->_countSubmission : 0; $msg = JText::sprintf('JSN_UNIFORM_YOU_CAN_ONLY_ACCEPT_UP_TO_300_SUBMISSION', (int) $countSubmission) . ' <a class="jsn-link-action" href="index.php?option=com_uniform&view=upgrade">' . JText::_("JSN_UNIFORM_UPGRADE_EDITION") . '</a>'; if ($this->_countSubmission <= 300) { JFactory::getApplication()->enqueueMessage($msg); } else { JError::raiseNotice(100, $msg); } } } $config = JSNConfigHelper::get(); // Load the submenu. $input = JFactory::getApplication()->input; JSNUniformHelper::addSubmenu($input->get('view', 'submissions')); // Get messages $msgs = ''; if (!$config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('SUBMISSIONS'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } // Initialize toolbar $this->initToolbar(); // Assign variables for rendering $this->assignRef('msgs', $msgs); parent::display($tpl); // Load assets JSNUniformHelper::addAssets(); $this->addAssets(); }
/** * Get the messages list markup. * * @return string */ protected function getInput() { // Preset output $html[] = ' <div class="jsn-page-list"> '; // Add assets $input = JFactory::getApplication()->input; if ($input->getInt('ajax') == 1) { $html[] = JSNHtmlAsset::loadScript('jsn/message', array('option' => $input->getCmd('option')), true); } else { JSNHtmlAsset::loadScript('jsn/message', array('option' => $input->getCmd('option'))); } // Get screen filter $screen = JFactory::getApplication()->input->getCmd('msg_screen'); // Create screen filter $screens = $this->getOptions(); array_unshift($screens, JHtml::_('select.option', '', JText::_('JSN_EXTFW_MESSAGE_FILTER_LIST'))); $screens = JHtml::_('select.genericlist', $screens, 'msg_screen', ' ', 'value', 'text', $screen); // Create refresh button and screen filter $html[] = ' <div class="jsn-fieldset-filter"> <fieldset> <div class="pull-left jsn-fieldset-search"> <a class="btn" title="' . JText::_('JSN_EXTFW_MESSAGE_REFRESH_LIST') . '" id="jsn-button-refresh" ajax-request="yes" ajax-target="#jsn-config-form > div" href="javascript:void(0)"><i class="icon-refresh"></i> ' . JText::_('JSN_EXTFW_MESSAGE_REFRESH_LIST') . '</a> </div> <div class="pull-right jsn-fieldset-select"> ' . $screens . ' </div> <div class="clearbreak"></div> </fieldset> </div> '; // Get message list $msgs = JSNUtilsMessage::getList($screen, true); // Render message list $html[] = JSNUtilsMessage::showConfig($msgs); $html[] = '<input type="hidden" name="' . $this->name . '" value="JSN_CONFIG_SKIP_SAVING" /></div>'; return implode($html); }
/** * Execute and display a template script. * * @param string $tpl The name of the template file to parse; automatically searches through the template paths. * * @return mixed A string if successful, otherwise a JError object. * * @see fetch() * @since 11.1 */ function display($tpl = null) { // Get config $config = JSNConfigHelper::get(); // Get messages $msgs = ''; if (!$config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('PROFIELS'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } // Initialize toolbar $this->initToolbar(); // Assign variables for rendering $this->assignRef('msgs', $msgs); // Set sub-menu JSNMobilizeHelper::addSubmenu('profiles'); // Display the view parent::display($tpl); // Load assets JSNMobilizeHelper::loadAssets(); $this->addAssets(); }
/** * Execute and display a template script. * * @param string $tpl The name of the template file to parse; automatically searches through the template paths. * * @return mixed A string if successful, otherwise a JError object. */ function display($tpl = null) { // Get config parameters $config = JSNConfigHelper::get(); // Initialize toolbar JSNUniformHelper::initToolbar('JSN_UNIFORM_ABOUT', 'uniform-about', false); // Get messages $msgs = ''; if (!$config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('ABOUT'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } // Load assets JSNUniformHelper::addAssets(); // Assign variables for rendering $this->assignRef('msgs', $msgs); // Load the submenu. $input = JFactory::getApplication()->input; JSNUniformHelper::addSubmenu($input->get('view', 'about')); // Display the template parent::display($tpl); }
/** * Execute and display a template script. * * @param string $tpl The name of the template file to parse; automatically searches through the template paths. * * @return mixed A string if successful, otherwise a JError object. * * @see fetch() * @since 11.1 */ function display($tpl = null) { // Get config $config = JSNConfigHelper::get(); // Get messages $msgs = ''; if (!$config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('FORMS'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } // Initialize toolbar $this->initToolbar(); // Load the submenu. $input = JFactory::getApplication()->input; JSNUniformHelper::addSubmenu($input->get('view', 'forms')); // Assign variables for rendering $this->assignRef('msgs', $msgs); // Display the view parent::display($tpl); // Load assets JSNUniformHelper::addAssets(); $this->addAssets(); }
/** * Display method * * @param string $tpl The name of the template file to parse; automatically searches through the template paths. * * @return void */ function display($tpl = null) { // Get config parameters $config = JSNConfigHelper::get(); // Set the toolbar JToolbarHelper::title(JText::_('JSN_EASYSLIDER_ABOUT_TITLE')); // Add toolbar menu JSNEasySliderHelper::addToolbarMenu(); // Set the submenu JSNEasySliderHelper::addSubmenu('about'); // Get messages $msgs = ''; if (!$config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('ABOUT'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } // Assign variables for rendering $this->assignRef('msgs', $msgs); // Add assets JSNEasySliderHelper::addAssets(); // Display the template parent::display($tpl); }
/** * Execute and display a template script. * * @param string $tpl The name of the template file to parse; automatically searches through the template paths. * * @return mixed A string if successful, otherwise a JError object. * * @see fetch() * @since 11.1 */ public function display($tpl = null) { // Initialize variables $input = JFactory::getApplication()->input; $this->_document = JFactory::getDocument(); $this->_item = $this->get('Item'); $this->_style = new stdClass(); $this->_styleContainer = ""; $this->_styleModule = ""; $this->_styleContentTitle = ""; $this->_styleContentBody = ""; $this->_form = $this->get('Form'); $this->_menuType = $this->get("MenuType"); $dataDesign = $this->get("DataDesign"); $this->_styleIcon = ""; $this->_os = $this->get("DataOS"); $osSupport = $this->get("DataOSSupport"); $this->_osSupport = array(); if (!empty($osSupport)) { foreach ($osSupport as $os) { $this->_osSupport[] = $os->os_id; } } $this->_dataDesign = array(); if (!empty($dataDesign)) { foreach ($dataDesign as $item) { $value = json_decode($item->value); if (!empty($value)) { $this->_dataDesign[$item->name] = $value; } else { $this->_dataDesign[$item->name] = $item->value; } } } $this->_style = !empty($this->_dataDesign['mobilize-style']) ? $this->_dataDesign['mobilize-style'] : ""; if (empty($this->_style->jsn_menu)) { @($this->_style->jsn_menu = '[{"key":"jsn_menu_container_bo_borderThickness","value":""},{"key":"jsn_menu_container_bo_borderStyle","value":"hidden"},{"key":"jsn_menu_container_bo_borderColor","value":""},{"key":"jsn_menu_container_ba_backgroundType","value":"Solid"},{"key":"jsn_menu_container_ba_soildColor","value":"#282828"},{"key":"jsn_menu_container_ba_gradientColor","value":"-moz-linear-gradient(-90deg, #ffffff 0%, #ffffff 100%)"},{"key":"jsn_menu_container_ba_activeColor","value":"#404040"},{"key":"jsn_menu_container_ic_iconColor","value":"#ffffff"},{"key":"jsn_menu_sublevel1_bo_borderThickness","value":""},{"key":"jsn_menu_sublevel1_bo_borderStyle","value":"hidden"},{"key":"jsn_menu_sublevel1_bo_borderColor","value":""},{"key":"jsn_menu_sublevel1_ba_normalColor","value":"#333333"},{"key":"jsn_menu_sublevel1_ba_activeColor","value":""},{"key":"jsn_menu_sublevel1_fo_fontFaceType","value":"standard fonts"},{"value":""},{"value":""},{"key":"jsn_menu_sublevel1_fo_fontFace","value":"Verdana"},{"key":"jsn_menu_sublevel1_fo_fontSize","value":""},{"key":"jsn_menu_sublevel1_fo_fontStyle","value":"inherit"},{"key":"jsn_menu_sublevel1_fo_fontColor","value":""},{"key":"jsn_menu_sublevel2_ba_normalColor","value":""},{"key":"jsn_menu_sublevel2_fo_fontFaceType","value":"standard fonts"},{"value":""},{"value":""},{"key":"jsn_menu_sublevel2_fo_fontFace","value":"Verdana"},{"key":"jsn_menu_sublevel2_fo_fontSize","value":""},{"key":"jsn_menu_sublevel2_fo_fontStyle","value":"inherit"},{"key":"jsn_menu_sublevel2_fo_fontColor","value":""}]'); } if (empty($this->_style->jsn_content_top)) { @($this->_style->jsn_content_top = '[{"key":"jsn_content_top_container_bo_borderThickness","value":""},{"key":"jsn_content_top_container_bo_borderStyle","value":"hidden"},{"key":"jsn_content_top_container_bo_borderColor","value":""},{"key":"jsn_content_top_container_ba_backgroundType","value":"Solid"},{"key":"jsn_content_top_container_ba_soildColor","value":"#404040"},{"key":"jsn_content_top_container_ba_gradientColor","value":"-moz-linear-gradient(-90deg, #ffffff 0%, #ffffff 100%)"},{"key":"jsn_content_top_container_sp_padding","value":""},{"key":"jsn_content_top_module_tabContainer_bo_borderThickness","value":""},{"key":"jsn_content_top_module_tabContainer_bo_borderStyle","value":"hidden"},{"key":"jsn_content_top_module_tabContainer_bo_borderColor","value":""},{"key":"jsn_content_top_module_tabContainer_ba_backgroundType","value":"Solid"},{"key":"jsn_content_top_module_tabContainer_ba_soildColor","value":""},{"key":"jsn_content_top_module_tabContainer_ba_gradientColor","value":"-moz-linear-gradient(-90deg, #ffffff 0%, #ffffff 100%)"},{"key":"jsn_content_top_module_tabContainer_bo_roundedCornerRadius","value":""},{"key":"jsn_content_top_module_tabContainer_sh_shadowSpread","value":""},{"key":"jsn_content_top_module_tabContainer_sh_shadowColor","value":""},{"key":"jsn_content_top_module_tabContainer_sp_margin","value":""},{"key":"jsn_content_top_module_tabContainer_sp_padding","value":""},{"key":"jsn_content_top_module_tabContent_title_fo_fontFaceType","value":"standard fonts"},{"value":""},{"value":""},{"key":"jsn_content_top_module_tabContent_title_fo_fontFace","value":"Verdana"},{"key":"jsn_content_top_module_tabContent_title_fo_fontSize","value":""},{"key":"jsn_content_top_module_tabContent_title_fo_fontStyle","value":"inherit"},{"key":"jsn_content_top_module_tabContent_title_fo_fontColor","value":""},{"key":"jsn_content_top_module_tabContent_body_fo_fontFaceType","value":"standard fonts"},{"value":""},{"value":""},{"key":"jsn_content_top_m_ct_fo_fontFace","value":"Verdana"},{"key":"jsn_content_top_module_tabContent_body_fo_fontSize","value":""},{"key":"jsn_content_top_module_tabContent_body_fo_fontStyle","value":"inherit"},{"key":"jsn_content_top_module_tabContent_body_fo_fontColor","value":""},{"key":"jsn_content_top_module_tabContent_link_linkColor","value":""}]'); } if (empty($this->_style->jsn_mainbody)) { @($this->_style->jsn_mainbody = '[{"key":"jsn_mainbody_container_sp_paddingleft","value":"20"},{"key":"jsn_mainbody_container_sp_paddingright","value":"20"},{"key":"jsn_mainbody_container_sp_paddingtop","value":"10"},{"key":"jsn_mainbody_container_sp_paddingbottom","value":"10"}]'); } if (empty($this->_style->jsn_user_bottom)) { @($this->_style->jsn_user_bottom = '[{"key":"jsn_user_bottom_container_bo_borderThickness","value":""},{"key":"jsn_user_bottom_container_bo_borderStyle","value":"hidden"},{"key":"jsn_user_bottom_container_bo_borderColor","value":""},{"key":"jsn_user_bottom_container_ba_backgroundType","value":"Solid"},{"key":"jsn_user_bottom_container_ba_soildColor","value":"#d9d9d9"},{"key":"jsn_user_bottom_container_ba_gradientColor","value":"-moz-linear-gradient(-90deg, #ffffff 0%, #ffffff 100%)"},{"key":"jsn_user_bottom_container_sp_padding","value":""},{"key":"jsn_user_bottom_module_tabContainer_bo_borderThickness","value":""},{"key":"jsn_user_bottom_module_tabContainer_bo_borderStyle","value":"hidden"},{"key":"jsn_user_bottom_module_tabContainer_bo_borderColor","value":""},{"key":"jsn_user_bottom_module_tabContainer_ba_backgroundType","value":"Solid"},{"key":"jsn_user_bottom_module_tabContainer_ba_soildColor","value":""},{"key":"jsn_user_bottom_module_tabContainer_ba_gradientColor","value":"-moz-linear-gradient(-90deg, #ffffff 0%, #ffffff 100%)"},{"key":"jsn_user_bottom_module_tabContainer_bo_roundedCornerRadius","value":""},{"key":"jsn_user_bottom_module_tabContainer_sh_shadowSpread","value":""},{"key":"jsn_user_bottom_module_tabContainer_sh_shadowColor","value":""},{"key":"jsn_user_bottom_module_tabContainer_sp_margin","value":""},{"key":"jsn_user_bottom_module_tabContainer_sp_padding","value":""},{"key":"jsn_user_bottom_module_tabContent_title_fo_fontFaceType","value":"standard fonts"},{"value":""},{"value":""},{"key":"jsn_user_bottom_module_tabContent_title_fo_fontFace","value":"Verdana"},{"key":"jsn_user_bottom_module_tabContent_title_fo_fontSize","value":""},{"key":"jsn_user_bottom_module_tabContent_title_fo_fontStyle","value":"inherit"},{"key":"jsn_user_bottom_module_tabContent_title_fo_fontColor","value":""},{"key":"jsn_user_bottom_module_tabContent_body_fo_fontFaceType","value":"standard fonts"},{"value":""},{"value":""},{"key":"jsn_user_bottom_m_ct_fo_fontFace","value":"Verdana"},{"key":"jsn_user_bottom_module_tabContent_body_fo_fontSize","value":""},{"key":"jsn_user_bottom_module_tabContent_body_fo_fontStyle","value":"inherit"},{"key":"jsn_user_bottom_module_tabContent_body_fo_fontColor","value":""},{"key":"jsn_user_bottom_module_tabContent_link_linkColor","value":""}]'); } if (empty($this->_style->jsn_content_bottom)) { @($this->_style->jsn_content_bottom = '[{"key":"jsn_content_bottom_container_bo_borderThickness","value":""},{"key":"jsn_content_bottom_container_bo_borderStyle","value":"hidden"},{"key":"jsn_content_bottom_container_bo_borderColor","value":""},{"key":"jsn_content_bottom_container_ba_backgroundType","value":"Solid"},{"key":"jsn_content_bottom_container_ba_soildColor","value":"#d9d9d9"},{"key":"jsn_content_bottom_container_ba_gradientColor","value":"-moz-linear-gradient(-90deg, #ffffff 0%, #ffffff 100%)"},{"key":"jsn_content_bottom_container_sp_padding","value":""},{"key":"jsn_content_bottom_module_tabContainer_bo_borderThickness","value":""},{"key":"jsn_content_bottom_module_tabContainer_bo_borderStyle","value":"hidden"},{"key":"jsn_content_bottom_module_tabContainer_bo_borderColor","value":""},{"key":"jsn_content_bottom_module_tabContainer_ba_backgroundType","value":"Solid"},{"key":"jsn_content_bottom_module_tabContainer_ba_soildColor","value":""},{"key":"jsn_content_bottom_module_tabContainer_ba_gradientColor","value":"-moz-linear-gradient(-90deg, #ffffff 0%, #ffffff 100%)"},{"key":"jsn_content_bottom_module_tabContainer_bo_roundedCornerRadius","value":""},{"key":"jsn_content_bottom_module_tabContainer_sh_shadowSpread","value":""},{"key":"jsn_content_bottom_module_tabContainer_sh_shadowColor","value":""},{"key":"jsn_content_bottom_module_tabContainer_sp_margin","value":""},{"key":"jsn_content_bottom_module_tabContainer_sp_padding","value":""},{"key":"jsn_content_bottom_module_tabContent_title_fo_fontFaceType","value":"standard fonts"},{"value":""},{"value":""},{"key":"jsn_content_bottom_module_tabContent_title_fo_fontFace","value":"Verdana"},{"key":"jsn_content_bottom_module_tabContent_title_fo_fontSize","value":""},{"key":"jsn_content_bottom_module_tabContent_title_fo_fontStyle","value":"inherit"},{"key":"jsn_content_bottom_module_tabContent_title_fo_fontColor","value":""},{"key":"jsn_content_bottom_module_tabContent_body_fo_fontFaceType","value":"standard fonts"},{"value":""},{"value":""},{"key":"jsn_content_bottom_m_ct_fo_fontFace","value":"Verdana"},{"key":"jsn_content_bottom_module_tabContent_body_fo_fontSize","value":""},{"key":"jsn_content_bottom_module_tabContent_body_fo_fontStyle","value":"inherit"},{"key":"jsn_content_bottom_module_tabContent_body_fo_fontColor","value":""},{"key":"jsn_content_bottom_module_tabContent_link_linkColor","value":""}]'); } if (empty($this->_style->jsn_logo)) { @($this->_style->jsn_logo = '[{"key":"jsn_logo_container_bo_borderThickness","value":""},{"key":"jsn_logo_container_bo_borderStyle","value":"solid"},{"key":"jsn_logo_container_bo_borderColor","value":""},{"key":"jsn_logo_container_ba_backgroundType","value":"Solid"},{"key":"jsn_logo_container_ba_soildColor","value":""},{"key":"jsn_logo_container_ba_gradientColor","value":"-moz-linear-gradient(-90deg, #ffffff 0%, #ffffff 100%)"},{"key":"jsn_logo_container_sp_paddingleft","value":""},{"key":"jsn_logo_container_sp_paddingright","value":""},{"key":"jsn_logo_container_sp_paddingbottom","value":""},{"key":"jsn_logo_container_sp_paddingtop","value":""},{"key":"jsn_logo_content_alignment","value":"center"}]'); } $this->_JSNMobilize = new JSNMobilize($this->_dataDesign); $this->_Modules = $this->_JSNMobilize->getModules(); $this->_defaultTempateSite = $this->_JSNMobilize->getTemplateDefault(); // Hide the main menu $input->set('hidemainmenu', true); // Initialize toolbar $this->initToolbar(); // Get config $config = JSNConfigHelper::get(); $msgs = ''; if (!$config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('PROFILE'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } // Assign variables for rendering $this->assignRef('msgs', $msgs); // Display the template parent::display($tpl); JSNMobilizeHelper::loadAssets(); $this->addAssets(); }
/** * Execute and display a template script. * * @param string $tpl The name of the template file to parse; automatically searches through the template paths. * * @return mixed A string if successful, otherwise a JError object. * * @see fetch() * @since 11.1 */ public function display($tpl = null) { // Initialize variables $session = JFactory::getSession(); $seesionQueue = $session->get('application.queue'); $input = JFactory::getApplication()->input; $this->urlAction = $input->getString('tmpl', ''); $this->_document = JFactory::getDocument(); $this->_item = $this->get('Item'); $emailModel = JModelForm::getInstance('EmailSettings', 'JSNUniformModel'); $this->checkSubmitModal = false; if ($seesionQueue[0]['type'] != "warning") { unset($_SESSION["__form-design-" . $this->_item->form_id]); unset($_SESSION["__form-design-"]); if ($seesionQueue[0]) { if ($this->urlAction == "component") { $this->checkSubmitModal = true; } } } $this->_listFontType = array(" Verdana, Geneva, sans-serif", "\"Times New Roman\", Times, serif", "\"Courier New\", Courier, monospace", "Tahoma, Geneva, sans-serif", "Arial, Helvetica, sans-serif", "\"Trebuchet MS\", Arial, Helvetica, sans-serif", "\"Arial Black\", Gadget, sans-serif", "\"Lucida Sans Unicode\", \"Lucida Grande\", sans-serif", "\"Palatino Linotype\", \"Book Antiqua\", Palatino, serif", "\"Comic Sans MS\", cursive"); $formContent = $this->_item->form_content; $this->_listPage = JSNUniformHelper::getListPage($formContent, $this->_item->form_id); $this->_form = $this->get('Form'); $this->_fromEmail = array(); if (empty($this->_item->form_id)) { $this->_fromConfig = $this->get('DataConfig'); $this->formAction = 0; $this->formActionData = ''; foreach ($this->_fromConfig as $formConfig) { if (isset($formConfig->name) && $formConfig->name == 'email_notification') { $this->_fromEmail = json_decode($formConfig->value); } if (isset($formConfig->name) && $formConfig->name == 'form_action') { $this->formAction = $formConfig->value; } } foreach ($this->_fromConfig as $formConfig) { if ($this->formAction == 1 && $formConfig->name == 'form_action_url') { $this->formActionData = $formConfig->value; } if ($this->formAction == 2 && $formConfig->name == 'form_action_menu') { $this->formActionData = json_decode($formConfig->value); } if ($this->formAction == 3 && $formConfig->name == 'form_action_article') { $this->formActionData = json_decode($formConfig->value); } if ($this->formAction == 4 && $formConfig->name == 'form_action_message') { $this->formActionData = $formConfig->value; } } } else { $this->_fromEmail = $this->get('FormEmail'); } $this->form_page = isset($formContent[0]->page_content) ? $formContent[0]->page_content : ""; $this->actionForm = array('redirect_to_url' => "", 'menu_item' => "", 'menu_item_title' => "", 'article' => "", 'article_title' => "", 'message' => "", 'action' => "1"); $this->actionForm = JSNUniformHelper::actionFrom($this->_item->form_post_action, $this->_item->form_post_action_data); $this->globalFormStyle = JSNUniformHelper::getDataConfig("form_style"); $this->formStyle = new stdClass(); if (!empty($this->_item->form_style)) { $this->formStyle = json_decode($this->_item->form_style); } else { $this->formStyle->themes_style->light = '{"background_color":"","background_active_color":"#FCF8E3","border_thickness":"0","border_color":"","border_active_color":"#FBEED5","rounded_corner_radius":"0","padding_space":"10","margin_space":"0","text_color":"#333333","font_type":" Verdana, Geneva, sans-serif","font_size":"14","field_background_color":"#ffffff","field_border_color":"","field_shadow_color":"","field_text_color":"#666666","message_error_background_color":"#B94A48","message_error_text_color":"#FFFFFF"}'; $this->formStyle->themes_style->dark = '{"background_color":"","background_active_color":"#444444","border_thickness":"0","border_color":"","border_active_color":"#666666","rounded_corner_radius":"0","padding_space":"10","margin_space":"0","text_color":"#C6C6C6","font_type":" Verdana, Geneva, sans-serif","font_size":"14","field_background_color":"#000000","field_border_color":"#111111","field_shadow_color":"#000000","field_text_color":"#333333","message_error_background_color":"#B94A48","message_error_text_color":"#FFFFFF"}'; $this->formStyle->themes = array('light', 'dark'); } if (!empty($this->globalFormStyle)) { $globalFormStyle = json_decode($this->globalFormStyle->value); if (!empty($globalFormStyle->themes_style)) { foreach ($globalFormStyle->themes_style as $key => $value) { $this->formStyle->themes_style->{$key} = $value; } } if (!empty($globalFormStyle->themes)) { foreach ($globalFormStyle->themes as $key => $value) { $this->formStyle->themes[] = $value; } } } if (!empty($this->formStyle->theme) && !empty($this->formStyle->themes_style) && $this->formStyle->theme != "jsn-style-light" && $this->formStyle->theme != "jsn-style-dark") { $theme = str_replace("jsn-style-", "", $this->formStyle->theme); if (!empty($this->formStyle->themes_style->{$theme})) { $styles = json_decode($this->formStyle->themes_style->{$theme}); } $this->formStyle->background_color = !empty($styles->background_color) ? $styles->background_color : ""; $this->formStyle->background_active_color = !empty($styles->background_active_color) ? $styles->background_active_color : ""; $this->formStyle->border_active_color = !empty($styles->border_active_color) ? $styles->border_active_color : ""; $this->formStyle->border_thickness = !empty($styles->border_thickness) ? $styles->border_thickness : ""; $this->formStyle->border_color = !empty($styles->border_color) ? $styles->border_color : ""; $this->formStyle->rounded_corner_radius = !empty($styles->rounded_corner_radius) ? $styles->rounded_corner_radius : ""; $this->formStyle->padding_space = !empty($styles->padding_space) ? $styles->padding_space : ""; $this->formStyle->margin_space = !empty($styles->margin_space) ? $styles->margin_space : ""; $this->formStyle->text_color = !empty($styles->text_color) ? $styles->text_color : ""; $this->formStyle->font_type = !empty($styles->font_type) ? $styles->font_type : ""; $this->formStyle->font_size = !empty($styles->font_size) ? $styles->font_size : ""; } else { $this->formStyle->background_color = !empty($this->formStyle->background_color) ? $this->formStyle->background_color : ""; $this->formStyle->background_active_color = !empty($this->formStyle->background_active_color) ? $this->formStyle->background_active_color : ""; $this->formStyle->border_active_color = !empty($this->formStyle->border_active_color) ? $this->formStyle->border_active_color : ""; $this->formStyle->border_thickness = !empty($this->formStyle->border_thickness) ? $this->formStyle->border_thickness : ""; $this->formStyle->border_color = !empty($this->formStyle->border_color) ? $this->formStyle->border_color : ""; $this->formStyle->rounded_corner_radius = !empty($this->formStyle->rounded_corner_radius) ? $this->formStyle->rounded_corner_radius : ""; $this->formStyle->padding_space = !empty($this->formStyle->padding_space) ? $this->formStyle->padding_space : ""; $this->formStyle->margin_space = !empty($this->formStyle->margin_space) ? $this->formStyle->margin_space : ""; $this->formStyle->text_color = !empty($this->formStyle->text_color) ? $this->formStyle->text_color : ""; $this->formStyle->font_type = !empty($this->formStyle->font_type) ? $this->formStyle->font_type : ""; $this->formStyle->font_size = !empty($this->formStyle->font_size) ? $this->formStyle->font_size : ""; if (empty($this->formStyle->background_active_color) && empty($this->formStyle->border_active_color) && empty($this->formStyle->border_thickness) && empty($this->formStyle->border_color) && empty($this->formStyle->rounded_corner_radius) && empty($this->formStyle->background_color) && empty($this->formStyle->font_size) && empty($this->formStyle->text_color) && empty($this->formStyle->margin_space) && empty($this->formStyle->padding_space)) { $this->formStyle->theme = ""; $this->formStyle->themes_style->light = '{"background_color":"","background_active_color":"#FCF8E3","border_thickness":"0","border_color":"","border_active_color":"#FBEED5","rounded_corner_radius":"0","padding_space":"10","margin_space":"0","text_color":"#333333","font_type":" Verdana, Geneva, sans-serif","font_size":"14","field_background_color":"#ffffff","field_border_color":"","field_shadow_color":"","field_text_color":"#666666","message_error_background_color":"#B94A48","message_error_text_color":"#FFFFFF"}'; $this->formStyle->themes_style->dark = '{"background_color":"","background_active_color":"#444444","border_thickness":"0","border_color":"","border_active_color":"#666666","rounded_corner_radius":"0","padding_space":"10","margin_space":"0","text_color":"#C6C6C6","font_type":" Verdana, Geneva, sans-serif","font_size":"14","field_background_color":"#000000","field_border_color":"#111111","field_shadow_color":"#000000","field_text_color":"#333333","message_error_background_color":"#B94A48","message_error_text_color":"#FFFFFF"}'; $this->formStyle->themes = array('light', 'dark'); } } // Hide the main menu $input->set('hidemainmenu', true); // Initialize toolbar $this->initToolbar(); // Get config $config = JSNConfigHelper::get(); $msgs = ''; if (!$config->get('disable_all_messages')) { $msgs = JSNUtilsMessage::getList('FORMS'); $msgs = count($msgs) ? JSNUtilsMessage::showMessages($msgs) : ''; } // Assign variables for rendering $this->assignRef('msgs', $msgs); // Display the template parent::display($tpl); // Load assets JSNUniformHelper::addAssets(); $this->addAssets(); }