コード例 #1
0
ファイル: view.html.php プロジェクト: densem-2013/exikom
 /**
  * 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);
 }
コード例 #2
0
 public function display($tpl = null)
 {
     $JSNMedia = JSNFactory::getMedia();
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.filter.js');
     // Check for errors.
     if (count($errors = $this->get('Errors'))) {
         JError::raiseError(500, implode("\n", $errors));
         return false;
     }
     $language = JFactory::getLanguage();
     $language->load('com_menus');
     $model = $this->getModel();
     $this->assign('model', $model);
     $menutype = '';
     $menutypeid = JRequest::getVar("menutypeid", '');
     if ($menutypeid) {
         JSNFactory::localimport('models.menuitem');
         $paMenuModel = new PoweradminModelMenuitem();
         $menutype = $paMenuModel->getMenuType($menutypeid);
     }
     $parentid = JRequest::getVar("parentid", '');
     $customScript = "\n\t\t\tvar selectMenuType;\n            (function(\$){\n\t\t\t\t\$(window).ready(function(){\n\t\t\t\t  \t  selectMenuType =  \$.jsnFilter(\n\t\t\t\t  \t  {\n\t\t\t  \t  \t\t  frameElement: \$('.jsn-menu-type'),\n\t\t\t  \t  \t\t  category    : true,\n\t\t\t\t\t  \t  itemClass   : '.jsn-item-type',\n\t\t\t\t\t  \t  totalColumn : 3,\n\t\t\t\t\t  \t  itemWidth   : 220,\n\t\t\t\t\t  \t  itemHeight  : 30,\n\t\t\t\t\t  \t  mPosLeft    : 0,\n\t\t\t\t\t  \t  mPosTop     : 15,\n\t\t\t\t\t  \t  marginOffset: {\n\t\t\t\t\t  \t  \t  right : 15,\n\t\t\t\t\t  \t  \t  bottom: 20\n\t\t\t\t\t  \t  },\n\t\t\t\t\t  \t  eventClick: function(){\n\t\t\t\t\t  \t  \t var params = \$(this).attr('params');\n\t\t\t\t\t  \t  \t window.parent.JoomlaShine.jQuery.addNewMenuItem(params, '" . $menutype . "', '" . $menutypeid . "', '" . $parentid . "');\n\t\t\t\t\t  \t  }\n\t\t\t\t  \t  \t}\n\t\t\t\t  \t  );\n\t\t\t\t  });\n\t\t\t  })(JoomlaShine.jQuery);\n\t\t";
     $JSNMedia->addScriptDeclaration($customScript);
     return parent::display();
 }
コード例 #3
0
ファイル: helper.php プロジェクト: jdrzaic/joomla-dummy
 /**
  * Load common assets.
  *
  * @param   boolean  $inline  Whether to load assets inline or load in header?
  *
  * @return  void
  */
 public static function loadAssets($inline = false)
 {
     // Define common stylesheets
     $stylesheets = array();
     if (JSNVersion::isJoomlaCompatible('3.0')) {
         $stylesheets[] = JSN_URL_ASSETS . '/3rd-party/jquery-ui/css/ui-bootstrap/jquery-ui-1.9.0.custom.css';
         if (preg_match('/msie/i', $_SERVER['HTTP_USER_AGENT'])) {
             $stylesheets[] = JSN_URL_ASSETS . '/3rd-party/jquery-ui/css/ui-bootstrap/jquery.ui.1.9.0.ie.css';
         }
     } else {
         $stylesheets[] = JSN_URL_ASSETS . '/3rd-party/bootstrap/css/bootstrap.min.css';
         $stylesheets[] = JSN_URL_ASSETS . '/3rd-party/jquery-ui/css/ui-bootstrap/jquery-ui-1.8.16.custom.css';
         if (preg_match('/msie/i', $_SERVER['HTTP_USER_AGENT'])) {
             $stylesheets[] = JSN_URL_ASSETS . '/3rd-party/jquery-ui/css/ui-bootstrap/jquery-ui-1.8.16.ie.css';
         }
     }
     $stylesheets[] = JSN_URL_ASSETS . '/joomlashine/css/jsn-gui.css';
     // Load stylesheets
     if (!$inline) {
         JSNHtmlAsset::addStyle($stylesheets);
     } else {
         foreach ($stylesheets as $stylesheet) {
             $html[] = '<link type="text/css" href="' . $stylesheet . '" rel="stylesheet" />';
         }
         echo implode("\n", $html);
     }
     // Load scripts
     if (JSNVersion::isJoomlaCompatible('3.2')) {
         JSNHtmlAsset::addScript(JUri::root(true) . '/media/jui/js/jquery.min.js');
     }
 }
コード例 #4
0
 /**
  *
  * Add Scripts and StyleSheets for this view
  * @param String $currentUrl
  */
 protected function addMedia($currentItemid, $render_url, $php_to_js)
 {
     $currentItemid = (int) $currentItemid;
     /** load libraries for the system rener **/
     $JSNTemplate = JSNFactory::getTemplate();
     $JSNMedia = JSNFactory::getMedia();
     $template = JFactory::getDocument()->template;
     $currUri = new JURI($render_url);
     JSNHtmlAsset::addStyle(JSN_POWERADMIN_STYLE_URI . 'uilayout/layout-default-latest.css');
     JSNHtmlAsset::addStyle(JSN_POWERADMIN_STYLE_URI . 'styles.css');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JS_URI . 'jquery.tinyscrollbar.js');
     JSNHtmlAsset::addScript(JSN_FRAMEWORK_ASSETS . '/3rd-party/jquery-hotkeys/jquery.hotkeys.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JS_URI . 'jquery-baseencode64.js');
     JSNHtmlAsset::addScript(JSN_FRAMEWORK_ASSETS . '/3rd-party/jquery-jstorage/jquery.jstorage.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.mousecheck.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.autodragdrop.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.rawmode.draganddrop.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.rawmode.component.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.rawmode.grid.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.functions.js');
     JSNHtmlAsset::addScript(JSN_FRAMEWORK_ASSETS . '/3rd-party/jquery-layout/js/jquery.layout-latest.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jstree/jstree.override.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.jstreecontext.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.submenu.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.menuitems.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.jquery.override.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.filter.js');
     //check sef on/off
     $sef = JFactory::getConfig()->get('sef');
     /** Add Custom Scripts **/
     $customScript = "\n\t\t\tvar jsnpoweradmin = true;\n\t\t\tvar baseUrl       = '" . JURI::root() . "';\n\t\t\tvar sef           = " . $sef . ";\n\t\t\tvar currentUrl    = '" . $render_url . "';\n\t\t\tvar lang          = '" . $JSNMedia->getLang() . "';\n\t\t\tvar positions     = new Array();\n\t\t\tvar JSNGrid, JSNComponent;\n\n\t\t\t(function(\$){\n\t\t\t    " . implode(PHP_EOL, $php_to_js) . "\n\t\t\t    \$.uiBackCompat = false;\n\t\t\t\t\$(document).ready(function(){\n\t\t\t\t\t\$('#page-loading').hide();\n\t\t\t\t\t\$('#jsn-rawmode-layout').css('visibility', 'visible');\n\t\t\t\t\tif (\$('#jsn-adminbar').size() == 0) {\n\t\t\t\t\t\t\$('body').addClass('no-adminbar');\n\t\t\t\t\t}\n\n\t\t\t\t\tfunction setFullScreen () {\n\t\t\t\t\t\t\$('body').toggleClass('jsn-fullscreen');\n\t\t\t\t\t\tif (\$('body').hasClass('jsn-fullscreen')) {\n\t\t\t\t\t\t\t\$('.header').hide();\n\t\t\t\t\t\t\t\$('.subhead-collapse').hide();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t\$('.header').show();\n\t\t\t\t\t\t\t\$('.subhead-collapse').show();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\$(window).trigger('resize');\n\t\t\t\t\t}\n\n\t\t\t\t\t\$('a#jsn-fullscreen').click(function () {\n\t\t\t\t\t\tsetFullScreen();\n\t\t\t\t\t\t\$.cookie('jsn-fullscreen', \$('body').hasClass('jsn-fullscreen'));\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t});\n\n\t\t\t\t\tvar isFullScreen = \$.cookie('jsn-fullscreen');\n\t\t\t\t\tif (isFullScreen !== undefined && (isFullScreen == 'true' || isFullScreen == '1')) {\n\t\t\t\t\t\tsetFullScreen();\n\t\t\t\t\t}\n\n\t\t\t\t\t\$.jStorage.set('selected_node', " . $currentItemid . ");\n\t\t\t\t\t\$.ajaxSetup({\n\t\t\t\t\t   timeout: 10000\n\t\t\t\t\t});\n\t\t\t\t\tJSNGrid      = new \$.JSNGrid();\n\t\t\t\t\tJSNComponent = new \$.JSNComponent('" . $currUri->getVar('option') . "', '" . $currUri->getVar('view') . "', '" . $currUri->getVar('layout') . "', '" . $currentItemid . "');\n \t\t\t\t\t\$._menuitems.mode  = 'rawmode';\n \t\t\t\t\t\$._menuitems.init();\n \t\t\t\t\t\$.jsnmouse.init();\n\t\t\t\t\tJSNFilter\t= new \$.JSNSpotligthModuleFilter(\$('#module_spotlight_filter'), {defaultText: '" . JText::_('JSN_RAWMODE_MODULE_FILTER_DEFAULT_TEXT', true) . "'});\n\t\t\t\t});\n\n\t\t\t})(JoomlaShine.jQuery);\n\t\t";
     $JSNMedia->addScriptDeclaration($customScript);
 }
コード例 #5
0
 /**
  * Display the view
  */
 public function display($tpl = null)
 {
     $JSNMedia = JSNFactory::getMedia();
     $JSNMedia->addStyleSheet(JSN_POWERADMIN_STYLE_URI . 'styles.css');
     JSNHtmlAsset::addScript(JSN_FRAMEWORK_ASSETS . '/3rd-party/jquery-hotkeys/jquery.hotkeys.js');
     JSNHtmlAsset::addScript(JSN_FRAMEWORK_ASSETS . '/3rd-party/jquery-jstorage/jquery.jstorage.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JS_URI . 'jquery.topzindex.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.submenu.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.mousecheck.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.functions.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JS_URI . 'jquery.tinyscrollbar.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.assignpages.js');
     JSNHtmlAsset::addScript(JSN_FRAMEWORK_ASSETS . '/3rd-party/jquery-jstree/jquery.jstree.js');
     $JSNMedia->addScriptDeclaration("var baseUrl = '" . JURI::root() . "';");
     //require helper
     JSNFactory::localimport('libraries.joomlashine.page.assignpages');
     $viewHelper = JSNAssignpages::getInstance();
     $menuTypes = $viewHelper->menuTypeDropDownList(false);
     $this->assign('menutypes', $menuTypes);
     $moduleid = JRequest::getVar('id', 0);
     $menuitems = $viewHelper->renderMenu($moduleid);
     $this->assign('menuitems', $menuitems);
     JSNFactory::localimport('libraries.joomlashine.modules');
     $assignType = JSNModules::checkAssign($moduleid);
     $this->assign('assignType', $assignType);
     $this->form = $this->get('Form');
     $this->item = $this->get('Item');
     $this->state = $this->get('State');
     $language = JFactory::getLanguage();
     $language->load('com_modules');
     parent::display($tpl);
 }
コード例 #6
0
 public function display($tpl = null)
 {
     $JSNMedia = JSNFactory::getMedia();
     $JSNMedia->addStyleSheet(JSN_POWERADMIN_STYLE_URI . 'styles.css');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JS_URI . 'jquery.cook.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JS_URI . 'jquery.tinyscrollbar.js');
     JSNHtmlAsset::addScript(JSN_FRAMEWORK_ASSETS . '/3rd-party/jquery-hotkeys/jquery.hotkeys.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jstree/jstree.override.js');
     JSNHtmlAsset::addScript(JSN_FRAMEWORK_ASSETS . '/3rd-party/jquery-jstorage/jquery.jstorage.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JS_URI . 'jquery.topzindex.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.submenu.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.mousecheck.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.functions.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.assignpages.js');
     $JSNMedia->addScriptDeclaration("var baseUrl = '" . JURI::root() . "';");
     //require classes
     JSNFactory::localimport('libraries.joomlashine.modules');
     JSNFactory::localimport('libraries.joomlashine.page.assignpages');
     $viewHelper = JSNAssignpages::getInstance();
     $menuTypes = $viewHelper->menuTypeDropDownList(false);
     $this->assign('menutypes', $menuTypes);
     $app = JFactory::getApplication();
     $moduleid = $app->getUserState('com_poweradmin.assignpages.custompage.moduleid', JRequest::getVar('moduleid', array(), 'get', 'array'));
     if (count($moduleid) == 1) {
         $menuitems = $viewHelper->renderMenu($moduleid[0]);
         $assignType = JSNModules::checkAssign($moduleid[0]);
     } else {
         $menuitems = $viewHelper->renderMenu(0);
         $assignType = 3;
     }
     $this->assign('menuitems', $menuitems);
     $this->assign('assignType', $assignType);
     return parent::display();
 }
コード例 #7
0
ファイル: view.html.php プロジェクト: densem-2013/exikom
 /**
  * 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)
 {
     // Load assets
     JSNUniformHelper::addAssets();
     parent::display($tpl);
     echo JSNHtmlAsset::loadScript('uniform/emailuser', array(), true);
 }
コード例 #8
0
ファイル: view.html.php プロジェクト: NallelyFlores89/basvec
 public function display($tpl = null)
 {
     $app = JFactory::getApplication();
     $document = JFactory::getDocument();
     // Check if this view is used for module editing page.
     $moduleEdit = JRequest::getCmd('moduleedit', '');
     $active_positions = array();
     $model = $this->getModel('changeposition');
     if (!$moduleEdit) {
         $moduleid = $app->getUserState('com_poweradmin.changeposition.moduleid');
     } else {
         $moduleid = array(JRequest::getCmd('moduleid', ''));
     }
     for ($i = 0; $i < count($moduleid); $i++) {
         $active_positions[] = "\$('#" . $model->getModulePosition($moduleid[$i]) . "-jsnposition').addClass('active-position').attr('title', 'Active position');";
     }
     JSNHtmlAsset::addScript(JURI::root(true) . '/media/jui/js/jquery.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.jquery.noconflict.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.functions.js');
     //$document->addScript(JSN_POWERADMIN_LIB_JSNJS_URI. 'jsn.filter.visualmode.js');
     //Enable position filter.
     $this->setFilterable(true);
     $customScript = "\n\t\t\tvar baseUrl  = '" . JURI::root() . "';\n\t\t\tvar moduleid = new Array();\n\t\t\tmoduleid = [" . @implode(",", $moduleid) . "];\n\t\t\t(function (\$){\n\t\t\t\t\$(document).ready(function (){\n\t\t\t\t\t" . implode(PHP_EOL, $active_positions) . "\n\t\t\t\t});\n\t\t\t})(JoomlaShine.jQuery);\n \t\t";
     $this->addCustomScripts($customScript);
     //Callback after position clicked.
     if (!$moduleEdit) {
         $onPostionClick = "\n \t\t\tif ( !\$(this).hasClass('active-position') ){\n\t\t\t\tJoomlaShine.jQuery.setPosition(moduleid, \$(this).attr('id').replace('-jsnposition', ''));\n \t\t\t\tparent.JoomlaShine.jQuery('.ui-dialog-content').dialog('close');\n \t\t\t}\n \t\t\t";
     } else {
         $onPostionClick = "\n \t\t\tif ( !\$(this).hasClass('active-position') ){\n \t\t\t\tvar posName = \$(this).attr('id').replace('-jsnposition', '');\n \t\t\t\tparent.JoomlaShine.jQuery('#jform_position').val(posName);\n \t\t\t\tparent.modal.close();\n \t\t\t}\n \t\t\t";
     }
     $this->addPositionClickCallBack($onPostionClick);
     parent::display($tpl);
 }
コード例 #9
0
 /**
  * Display the view
  */
 public function display($tpl = null)
 {
     // Include the component HTML helpers.
     JSNFactory::import('components.com_content.helpers.content');
     JSNFactory::import('components.com_content.helpers.html.contentadministrator');
     $JSNMedia = JSNFactory::getMedia();
     $JSNMedia->addStyleSheet(JSN_POWERADMIN_STYLE_URI . 'content.css');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.content.js');
     if ($this->getLayout() == 'pagebreak') {
         // TODO: This is really dogy - should change this one day.
         $eName = JRequest::getVar('e_name');
         $eName = preg_replace('#[^A-Z0-9\\-\\_\\[\\]]#i', '', $eName);
         $document = JFactory::getDocument();
         $document->setTitle(JText::_('COM_CONTENT_PAGEBREAK_DOC_TITLE'));
         $this->assignRef('eName', $eName);
         parent::display($tpl);
         return;
     }
     // Initialiase variables.
     $this->form = $this->get('Form');
     $this->item = $this->get('Item');
     $this->state = $this->get('State');
     $this->canDo = ContentHelper::getActions($this->state->get('filter.category_id'));
     // Check for errors.
     if (count($errors = $this->get('Errors'))) {
         JError::raiseError(500, implode("\n", $errors));
         return false;
     }
     $language = JFactory::getLanguage();
     $language->load('com_content');
     parent::display($tpl);
 }
コード例 #10
0
    /**
     * Generate html for PageBuilder layout.
     * 
     * @return string
     */
    public function html()
    {
        $helper = new JSNPagebuilderHelpersBuilder();
        JSNHtmlAsset::addScript(JSNPB_ADMIN_URL . '/assets/js/elements-lang.js');
        JSNHtmlAsset::addScript(JSNPB_ADMIN_URL . '/assets/js/handle.js');
        JSNHtmlAsset::addScript(JSNPB_ADMIN_URL . '/assets/js/shortcodesetting/settings-handler.js');
        // Genrate pagebuilder element template.
        $helper->generateElementColumnTemplate();
        $helper->generateElementRowTemplate();
        $source_content = '';
        $data = array();
        $source_content = $_POST['form_data'];
        // Remove all p tags which auto added by the editor
        $source_content = JSNPagebuilderHelpersShortcode::removeAutop($source_content);
        $source_content = html_entity_decode($source_content, ENT_COMPAT, 'UTF-8');
        $html[] = '<link rel="stylesheet" href="' . JSNPB_ADMIN_URL . '/assets/css/jsn-element-font.css' . '" type="text/css" />';
        $html[] = '<link rel="stylesheet" href="' . JSNPB_ADMIN_URL . '/assets/css/pb-layout-font.css' . '" type="text/css" />';
        $html[] = '<div id="form-container" class="jsn-layout jsn-section-content">';
        if ($source_content) {
            //$shortcodeTags		= $helper->getShortcodeTags();
            $html[] = $helper->generateShortCode($source_content);
        } else {
            $html[] = $helper->getRowStructure();
        }
        $html[] = '<a href="javascript:void(0);" id="jsn-add-container"
						class="jsn-add-more jsn-add-more-row"><i class="icon-plus"></i> Add Row
					</a>';
        /**
         * Show thumbnail for default layouts
         */
        $html[] = '<div class="row-fluid pb-layout-thumbs">';
        $layouts = JSNPBShortcodeRow::$layouts;
        foreach ($layouts as $columns) {
            $columns_name = implode('x', $columns);
            $icon_class = implode('-', $columns);
            $data_columns = implode(',', $columns);
            $icon_class = 'pb-layout-' . $icon_class;
            $icon = '<i class="' . $icon_class . '"></i>';
            $html[] = '<div class="thumb-wrapper" data-columns="' . $data_columns . '" title="' . $columns_name . '">' . $icon . '</div>';
        }
        $html[] = '</div>';
        $html[] = JSNHtmlGenerate::footer(array(), false);
        $html[] = '</div>';
        $html[] = $helper->getAddShortcodesPopup();
        if (defined("JSN_PAGEBUILDER_EDITION")) {
            if (strtolower(JSN_PAGEBUILDER_EDITION) == "free") {
                if (file_exists(JPATH_ROOT . '/administrator/components/com_pagebuilder/helpers/articles.php')) {
                    include_once JPATH_ROOT . '/administrator/components/com_pagebuilder/helpers/articles.php';
                    $pbTotal = JSNPagebuilderHelpersArticles::getCountArticleUsedPageBuilderFromPlugin();
                    if ($pbTotal >= 5 && !JFactory::getApplication()->input->getInt('article_id') && JFactory::getApplication()->input->getInt('is_com_modules') != 1) {
                        $html = array();
                        $html[] = '<div class="jsn-bootstrap3"><div class="pb-element-container"><p class="jsn-bglabel">You have reached 5 pages limit of using JSN PageBuilder.</p><p style="font-size: 20px;text-align: center;color: #d3d3d3;">Please  to upgrade <a target=\'_blank\' href=\'' . JSN_PAGEBUILDER_INFO_LINK . '\'>Pro version</a> or remove your old pages that used JSN PageBuilder.</p><div style="text-align: center"><a href="index.php?option=com_pagebuilder&view=upgrade" target="_blank" class="btn-primary btn-large btn"> Upgrade </a></div></div></div>';
                    }
                }
            }
        }
        print_r(implode("\n", $html));
        exit;
    }
コード例 #11
0
 /**
  * Add the libraries css and javascript
  *
  * @return void
  *
  * @since        1.6
  */
 protected function addAssets()
 {
     JSNHtmlAsset::registerDepends('uniform/libs/googlemaps/jquery.ui.map', array('jquery', 'jquery.ui'));
     JSNHtmlAsset::registerDepends('uniform/libs/googlemaps/jquery.ui.map.services', array('jquery', 'jquery.ui', 'uniform/libs/googlemaps/jquery.ui.map'));
     JSNHtmlAsset::registerDepends('uniform/libs/googlemaps/jquery.ui.map.extensions', array('jquery', 'jquery.ui', 'uniform/libs/googlemaps/jquery.ui.map'));
     JSNHtmlAsset::addScript('http://maps.google.com/maps/api/js?sensor=false&libraries=places');
     echo JSNHtmlAsset::loadScript('uniform/submission', array('nextAndPreviousForm' => $this->nextAndPreviousForm), true);
 }
コード例 #12
0
ファイル: item.php プロジェクト: densem-2013/exikom
 /**
  * Include admin scripts
  *
  * @return type
  */
 public function backend_element_assets()
 {
     $document = JFactory::getDocument();
     JSNHtmlAsset::addScript(JSNPB_ELEMENT_URL . '/pricingtable/assets/js/pricingtable-settings.js', 'text/javascript');
     JSNPagebuilderHelpersFunctions::print_asset_tag(JSNPB_ELEMENT_URL . '/pricingtable/assets/js/item_pricingtable.js', 'js');
     JSNPagebuilderHelpersFunctions::print_asset_tag(JSNPB_ELEMENT_URL . '/pricingtable/assets/css/item_pricingtable.css', 'css');
     JSNPagebuilderHelpersFunctions::print_asset_tag(JSNPB_ADMIN_URL . '/assets/joomlashine/js/jsn-linktype.js', 'js');
 }
コード例 #13
0
ファイル: view.html.php プロジェクト: NallelyFlores89/basvec
 /**
  * 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.
  */
 public function display($tpl = null)
 {
     // Add assets
     $document = JFactory::getDocument();
     JSNHtmlAsset::loadScript('mobilize/menus');
     $document->addStyleSheet(JURI::base(true) . '/components/com_mobilize/assets/css/mobilize.css');
     parent::display($tpl);
 }
コード例 #14
0
ファイル: jsnshowcase.php プロジェクト: jdrzaic/joomla-dummy
 protected function getInput()
 {
     $uri = JURI::root(true);
     $enabledCSS = ' jsn-disable';
     $menuid = JRequest::getInt('id');
     $app = JFactory::getApplication();
     $showcaseID = $app->getUserState('com_imageshow.add.showcase_id');
     if ($showcaseID != 0) {
         $this->value = $showcaseID;
         $app->setUserState('com_modules.add.showcase_id', 0);
     }
     $document = JFactory::getDocument();
     $input = $app->input;
     $option = $input->getCmd('option', '');
     $view = $input->getCmd('view', '');
     if ($option == 'com_advancedmodules' && $view == 'module') {
         if (file_exists(JPATH_ROOT . '/media/jui/js/jquery.simplecolors.min.js')) {
             $document->addScript(JUri::root(true) . '/media/jui/js/jquery.simplecolors.min.js');
         }
     }
     !class_exists('JSNBaseHelper') or JSNBaseHelper::loadAssets();
     JHTML::stylesheet('modules/mod_imageshow/assets/css/style.css');
     JHTML::stylesheet('administrator/components/com_imageshow/assets/css/imageshow.css');
     JSNHtmlAsset::addScript($uri . '/media/jui/js/jquery.min.js');
     JSNHtmlAsset::addScript(JSN_URL_ASSETS . '/3rd-party/jquery-ui/js/jquery-ui-1.9.0.custom.min.js');
     JHTML::script('administrator/components/com_imageshow/assets/js/joomlashine/window.js');
     JHTML::script('modules/mod_imageshow/assets/js/jsnis_module.js');
     JSNHtmlAsset::addScript($uri . '/administrator/components/com_imageshow/assets/js/joomlashine/conflict.js');
     $jsCode = "\n\t\t\tvar baseUrl = '" . JURI::root() . "';\n\t\t\tvar gIframeFunc = undefined;\n\t\t\t(function(\$){\n\t\t\t\t\$(document).ready(function () {\n\t\t\t\t\tvar wWidth  = \$(window).width()*0.9;\n\t\t\t\t\tvar wHeight = \$(window).height()*0.8;\n\t\t\t\t\t\$('.jsn-is-showcase-modal').click(function(event){\n\t\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\t\tvar link = baseUrl+'administrator/'+\$(this).attr('href')+'&tmpl=component';\n\t\t\t\t\t\tvar save_button_lable = '" . JText::_('JSN_IMAGESHOW_SAVE_AND_SELECT', true) . "';\n\t\t\t\t\t\tvar JSNISShowcaseWindow = new \$.JSNISUIWindow(link,{\n\t\t\t\t\t\t\t\twidth: wWidth,\n\t\t\t\t\t\t\t\theight: wHeight,\n\t\t\t\t\t\t\t\ttitle: '" . JText::_('JSN_IMAGESHOW_SHOWCASE_SETTINGS') . "',\n\t\t\t\t\t\t\t\tscrollContent: true,\n\t\t\t\t\t\t\t\tbuttons:\n\t\t\t\t\t\t\t\t[{\n\t\t\t\t\t\t\t\t\ttext:save_button_lable,\n\t\t\t\t\t\t\t\t\tclass: 'ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only',\n\t\t\t\t\t\t\t\t\tclick: function (){\n\t\t\t\t\t\t\t\t\t\tif(typeof gIframeFunc != 'undefined')\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tgIframeFunc();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tconsole.log('Iframe function not available')\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\ttext: '" . JText::_('JSN_IMAGESHOW_CANCEL', true) . "',\n\t\t\t\t\t\t\t\t\tclass: 'ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only',\n\t\t\t\t\t\t\t\t\tclick: function (){\n\t\t\t\t\t\t\t\t\t\t\$(this).dialog('close');\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\t]\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t});\n\t\t\t})((typeof JoomlaShine != 'undefined' && typeof JoomlaShine.jQuery != 'undefined') ? JoomlaShine.jQuery : jQuery);\n\t\t  ";
     $document = JFactory::getDocument();
     $document->addScriptDeclaration($jsCode);
     $db = JFactory::getDBO();
     JHTML::stylesheet('modules/mod_imageshow/assets/css/style.css');
     //build the list of categories
     $query = 'SELECT a.showcase_title AS text, a.showcase_id AS id' . ' FROM #__imageshow_showcase AS a' . ' WHERE a.published = 1' . ' ORDER BY a.ordering';
     $db->setQuery($query);
     $data = $db->loadObjectList();
     $results[] = JHTML::_('select.option', '0', '- ' . JText::_('JSN_FIELD_SELECT_SHOWCASE') . ' -', 'id', 'text');
     $results = array_merge($results, $data);
     if ($data) {
         $enabledCSS = '';
         if (!$menuid && is_null($showcaseID)) {
             $this->value = $data[0]->id;
         }
     } else {
         $this->value = '0';
     }
     $html = "<div id='jsn-showcase-icon-warning'>";
     $html .= JHTML::_('select.genericList', $results, $this->name, 'class="inputbox jsn-select-value' . $enabledCSS . '" style="width: 250px;"', 'id', 'text', $this->value, $this->id);
     if (!$data) {
         $html .= '<span><i>' . JText::_('JSN_DO_NOT_HAVE_ANY_SHOWCASE') . '</i></span>';
     }
     $html .= "<span><i class=\"jsn-icon16 jsn-icon-warning-sign icon-warning" . $enabledCSS . "\" id = \"showcase-icon-warning\"><span class=\"jsn-tooltip-wrap\"><span class=\"jsn-tooltip-anchor\"></span><p class=\"jsn-tooltip-title\">" . JText::_('JSN_FIELD_TITLE_SHOWCASE_WARNING') . "</p>" . JText::_('JSN_FIELD_DES_SHOWCASE_WARNING') . "</span></i></span>";
     $html .= "<a class=\"jsn-link-edit-showcase jsn-is-showcase-modal\" id=\"jsn-link-edit-showcase\" href=\"javascript: void(0);\" rel='{\"action\": \"edit\"}' title=\"" . JText::_('EDIT_SELECTED_SHOWCASE') . "\"><i class=\"jsn-icon16 jsn-icon-pencil\" id=\"showcase-icon-edit\"></i></a>";
     $html .= "<a class=\"jsn-is-showcase-modal\" href=\"index.php?option=com_imageshow&controller=showcase&task=add\" rel='{\"action\": \"add\"}' title=\"" . JText::_('CREATE_NEW_SHOWCASE') . "\"><i class=\"jsn-icon16 jsn-icon-plus\" id=\"showcase-icon-add\"></i></a>";
     $html .= "</div>";
     return $html;
 }
コード例 #15
0
ファイル: jsnfield.php プロジェクト: NallelyFlores89/basvec
 /**
  * Method to get the field input markup.
  *
  * @return  string  The field input markup.
  *
  * @since   11.1
  */
 protected function getInput()
 {
     $columnTableFormData = JSNUniformHelper::getFormData();
     $arrayTranslated = array();
     $html = "<div class=\"jsn-master\"><div id=\"page-loading\" class=\"jsn-bgloading\"><i class=\"jsn-icon32 jsn-icon-loading\"></i></div><div class=\"jsn-bootstrap menu-items\"><input type='hidden' id='uniform_field' name='" . $this->name . "' value='" . $this->value . "' /><ul class=\"jsn-items-list ui-sortable hide\" id=\"form_field\">";
     $html .= "</ul></div></div>";
     JSNHtmlAsset::loadScript('uniform/menusubmissions', array('value' => $this->value, 'name' => 'uniform_listField', 'columnTableFormData' => $columnTableFormData, 'language' => JSNUtilsLanguage::getTranslated($arrayTranslated)));
     return $html;
 }
コード例 #16
0
ファイル: view.html.php プロジェクト: densem-2013/exikom
 /**
  * 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)
 {
     $baseUrl = JURI::base(true);
     $document = JFactory::getDocument();
     JSNHtmlAsset::addScriptPath('mobilize', $baseUrl . '/components/com_mobilize/assets/js');
     JSNHtmlAsset::loadScript('mobilize/modules');
     $document->addStyleSheet(JURI::base(true) . '/components/com_mobilize/assets/css/mobilize.css');
     parent::display($tpl);
 }
コード例 #17
0
ファイル: view.html.php プロジェクト: densem-2013/exikom
 /**
  * Add the libraries css and javascript
  *
  * @return void
  *
  * @since        1.6
  */
 protected function addAssets()
 {
     JSNHtmlAsset::registerDepends('uniform/libs/googlemaps/jquery.ui.map', array('jquery', 'jquery.ui'));
     JSNHtmlAsset::registerDepends('uniform/libs/googlemaps/jquery.ui.map.services', array('jquery', 'jquery.ui', 'uniform/libs/googlemaps/jquery.ui.map'));
     JSNHtmlAsset::registerDepends('uniform/libs/googlemaps/jquery.ui.map.extensions', array('jquery', 'jquery.ui', 'uniform/libs/googlemaps/jquery.ui.map'));
     $uri = JUri::getInstance();
     JSNHtmlAsset::addScript($uri->getScheme() . '://maps.google.com/maps/api/js?sensor=false&libraries=places');
     echo JSNHtmlAsset::loadScript('uniform/submission', array('nextAndPreviousForm' => $this->nextAndPreviousForm), true);
     JSNHtmlAsset::addScript(JSN_UNIFORM_ASSETS_URI . '/js/jsn.jquery.noconflict.js');
 }
コード例 #18
0
ファイル: view.php プロジェクト: jdrzaic/joomla-dummy
 /**
  * Display the view
  *
  * @param   string  $tpl  The name of the template file to parse; automatically searches through the template paths.
  *
  * @return  void
  */
 public function display($tpl = null)
 {
     // Include the component HTML helpers.
     $this->_path['template'] = array(JPATH_ROOT . '/plugins/system/jsnframework/libraries/joomlashine/menuitems/tmpl');
     JHtml::addIncludePath(JPATH_COMPONENT . '/helpers/html');
     // Load assets
     JSNBaseHelper::loadAssets();
     parent::display($tpl);
     echo JSNHtmlAsset::loadScript('jsn/selectorFilter', array(), true);
 }
コード例 #19
0
ファイル: helper.php プロジェクト: jdrzaic/joomla-dummy
 /**
  * Method to render HTML markup for a form as declared in an JForm object.
  *
  * @param   object  $form       JForm object.
  * @param   string  $nameSpace  Prefix field name with the given name-space, e.g. jform[params]
  *
  * @return  string  Generated HTML markup.
  */
 public static function render($form, $nameSpace = '')
 {
     $html = array();
     // Get fieldsets
     foreach ($form->getFieldsets() as $fieldset) {
         if (isset($fieldset->skipRender) and (int) $fieldset->skipRender) {
             continue;
         }
         // Get fieldset attributes
         $tag = isset($fieldset->markupTag) ? strtolower($fieldset->markupTag) : 'fieldset';
         $label = $tag == 'fieldset' ? 'legend' : 'h4';
         $class = isset($fieldset->class) ? ' class="' . $fieldset->class . '"' : '';
         // Generate open tag
         $html[] = "<{$tag}{$class}>";
         // Generate form legend if declared
         if ($fieldset->label) {
             $html[] = "\t<{$label}" . ($label == 'h4' ? ' class="jsn-section-header"' : '') . '>' . JText::_($fieldset->label) . "</{$label}>";
         }
         foreach ($form->getFieldset($fieldset->name) as $field) {
             // Generate field container ID
             $id = ' id="' . $field->id . '-container' . '"';
             if ($field->label) {
                 // Initialize field label markup
                 if (strpos($field->label, 'class=') === false) {
                     $label = str_replace('<label', '<label class="control-label"', $field->label);
                 } else {
                     $label = strpos($field->label, 'control-label') === false ? preg_replace('/<label(\\s+[^>]*)class="([^"]*)"([^>]*)>/', '<label\\1class="control-label \\2"\\3>', $field->label) : $field->label;
                 }
                 // Initialize field label tooltips
                 if (strpos($label, ' hasTip')) {
                     $label = preg_replace(array('/ hasTip/', '/title="[^:]*::/'), array('', 'original-title="'), $label);
                 }
                 // Generate markup for input field with field label
                 $html[] = "\t" . '<div' . $id . ' class="control-group">' . $label . '<div class="controls">' . $field->input . '</div></div>';
             } else {
                 // Generate markup for input field without field label
                 $html[] = "\t" . "<div{$id}>{$field->input}</div>";
             }
         }
         // Generate close tag
         $html[] = "</{$tag}>";
     }
     // Finalize form markup
     $html = implode("\n", $html);
     // Set name-space prefix
     if (!empty($nameSpace)) {
         $html = str_replace('name="jform[', 'name="' . $nameSpace . '[', $html);
     }
     // Setup tooltips
     JSNHtmlAsset::addStyle(JSN_URL_ASSETS . '/3rd-party/jquery-tipsy/tipsy.css');
     JSNHtmlAsset::loadScript('jsn/tooltips');
     // Setup form validation
     JSNHtmlAsset::loadScript('jsn/validate', array('id' => 'jsn-config-form', 'lang' => JSNUtilsLanguage::getTranslated(array('JSN_EXTFW_INVALID_VALUE_TYPE', 'JSN_EXTFW_ERROR_FORM_VALIDATION_FAILED', 'JSN_EXTFW_SYSTEM_CUSTOM_ASSETS_INVALID'))));
     return $html;
 }
コード例 #20
0
ファイル: view.html.php プロジェクト: densem-2013/exikom
 public function display($tpl = null)
 {
     // Set the toolbar
     JToolbarHelper::title(JText::_('JSN_SAMPLE_UPGRADE_PRODUCT'));
     JSNHtmlAsset::addStyle(JSNPB_FRAMEWORK_ASSETS . '/joomlashine/css/jsn-gui.css');
     // Add assets
     $this->_document = JFactory::getDocument();
     $this->addToolbar();
     // Display the template
     parent::display($tpl);
 }
コード例 #21
0
 public function display($tpl = null)
 {
     $app = JFactory::getApplication();
     $JSNMedia = JSNFactory::getMedia();
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.datas.validation.js');
     $JSNMedia->addScriptDeclaration("\n\t\t\tvar baseUrl = '" . JURI::root() . "';\n\t\t\t(function(\$){\n\t\t\t\t\$(window).ready(function(){\n\t\t\t\t\t\$('#jsn-component-settings').textboxDataNumberic({maxValue:500});\n\t\t\t\t\t\$('.apply-setting-area').click(function(){\n\t\t\t\t\t\tif (\$(this).children('input').val() == 'globally'){\n\t\t\t\t\t\t\t\$(this).children('input').val('only');\n\t\t\t\t\t\t\t\$(this).children('span.symbol-only').show();\n\t\t\t\t\t\t\t\$(this).children('span.symbol-globally').hide();\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\$(this).children('span.symbol-only').hide();\n\t\t\t\t\t\t\t\$(this).children('span.symbol-globally').show();\n\t\t\t\t\t\t\t\$(this).children('input').val('globally');\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t});\n\t\t\t})(JoomlaShine.jQuery);\n\t\t");
     $JSNConfig = JSNFactory::getConfig();
     $params = $JSNConfig->getMenuParams($app->getUserState('com_poweradmin.component.menuid', 0));
     $JSNConfig->megreGlobalParams('com_content', $params, true);
     $this->assign('params', $params);
     return parent::display();
 }
コード例 #22
0
ファイル: view.html.php プロジェクト: densem-2013/exikom
 public function display($tpl = null)
 {
     // Get config parameters
     $config = JSNConfigHelper::get();
     // Set the toolbar
     JToolBarHelper::title(JText::_('JSN_PAGEBUILDER_BUILDER_UPDATE_TITLE'));
     // Add assets
     JSNHtmlAsset::addStyle(JSN_URL_ASSETS . '/joomlashine/css/jsn-gui.css');
     $redirAfterFinish = 'index.php?option=com_pagebuilder&view=about';
     $this->assign('redirAfterFinish', $redirAfterFinish);
     // Display the template
     parent::display($tpl);
 }
コード例 #23
0
ファイル: view.html.php プロジェクト: NallelyFlores89/basvec
 /**
  * Add nesscessary JS & CSS files
  *
  * @return void
  */
 private function _addAssets()
 {
     $objJSNMedia = JSNISFactory::getObj('classes.jsn_is_media');
     !class_exists('JSNBaseHelper') or JSNBaseHelper::loadAssets();
     $objJSNMedia->addStyleSheet(JURI::root(true) . '/administrator/components/com_imageshow/assets/css/imageshow.css');
     JSNHtmlAsset::addScript(JURI::root(true) . '/media/jui/js/jquery.min.js');
     $objJSNMedia->addScript(JURI::root(true) . '/administrator/components/com_imageshow/assets/js/joomlashine/conflict.js');
     JSNHtmlAsset::addScript(JSN_URL_ASSETS . '/3rd-party/jquery-ui/js/jquery-ui-1.9.0.custom.min.js');
     // Add toolbar menu
     JSNISImageShowHelper::addToolbarMenu();
     // Set the submenu
     JSNISImageShowHelper::addSubmenu('about');
 }
コード例 #24
0
ファイル: view.html.php プロジェクト: NallelyFlores89/basvec
 /**
  * Add nesscessary JS & CSS files
  *
  * @return void
  */
 private function _addAssets()
 {
     $objJSNMedia = JSNISFactory::getObj('classes.jsn_is_media');
     JSNHtmlAsset::addScript(JURI::root(true) . '/media/jui/js/jquery.min.js');
     $objJSNMedia->addScript(JURI::root(true) . '/administrator/components/com_imageshow/assets/js/joomlashine/conflict.js');
     JSNHtmlAsset::addScript(JSN_URL_ASSETS . '/3rd-party/jquery-ck/jquery.ck.js');
     JSNHtmlAsset::addScript(JSN_URL_ASSETS . '/3rd-party/jquery-jwysiwyg/jquery.wysiwyg.js');
     JSNHtmlAsset::addStyle(JSN_URL_ASSETS . '/3rd-party/jquery-jwysiwyg/jquery.wysiwyg.css');
     JSNHtmlAsset::addScript(JSN_URL_ASSETS . '/3rd-party/jquery-ui/js/jquery-ui-1.9.0.custom.min.js');
     !class_exists('JSNBaseHelper') or JSNBaseHelper::loadAssets();
     $objJSNMedia->addStyleSheet(JURI::root(true) . '/administrator/components/com_imageshow/assets/css/imageshow.css');
     $objJSNMedia->addStyleSheet(JURI::root(true) . '/administrator/components/com_imageshow/assets/css/image_selector.css');
     JSNHtmlAsset::loadScript('imageshow/joomlashine/showlist', array('pathRoot' => JURI::root(), 'language' => JSNUtilsLanguage::getTranslated(array('JSN_IMAGESHOW_OK', 'JSN_IMAGESHOW_CLOSE'))));
 }
コード例 #25
0
ファイル: view.php プロジェクト: jdrzaic/joomla-dummy
 /**
  * Display the view
  *
  * @param   string  $tpl  The name of the template file to parse.
  *
  * @return  void
  */
 public function display($tpl = null)
 {
     // Include the component HTML helpers.
     if (!JFactory::getUser()->authorise('core.manage', 'com_users')) {
         return JError::raiseWarning(404, JText::_('JERROR_ALERTNOAUTHOR'));
     }
     // Include the component HTML helpers.
     $this->_path['template'] = array(JPATH_ROOT . '/plugins/system/jsnframework/libraries/joomlashine/users/tmpl');
     JHtml::addIncludePath(JPATH_COMPONENT . '/helpers/html');
     // Load assets
     JSNBaseHelper::loadAssets();
     parent::display($tpl);
     echo JSNHtmlAsset::loadScript('jsn/selectorFilter', array(), true);
 }
コード例 #26
0
ファイル: view.php プロジェクト: jdrzaic/joomla-dummy
 /**
  * Display method.
  *
  * @param   string  $tpl  The name of the template file to parse.
  *
  * @return	void
  */
 public function display($tpl = null)
 {
     // Get config declaration
     $configDeclaration = $this->get('Form');
     // Pass data to view
     $this->assignRef('config', $configDeclaration);
     // Load assets
     JSNBaseHelper::loadAssets();
     JSNHtmlAsset::addStyle(JSN_URL_ASSETS . '/3rd-party/jquery-tipsy/tipsy.css');
     JSNHtmlAsset::loadScript('jsn/core', array('lang' => JSNUtilsLanguage::getTranslated(array('JSN_EXTFW_GENERAL_LOADING', 'JSN_EXTFW_GENERAL_CLOSE'))));
     JSNHtmlAsset::loadScript('jsn/config');
     // Display the template
     parent::display($tpl);
 }
コード例 #27
0
 public function display($tpl = null)
 {
     // Get config parameters
     $config = JSNConfigHelper::get();
     // Set the toolbar
     JToolBarHelper::title(JText::_('JSN_POWERADMIN_UPDATE_TITLE'));
     // Add assets
     $document = JFactory::getDocument();
     JSNHtmlAsset::addStyle(PoweradminHelper::makeUrlWithSuffix(JSN_URL_ASSETS . '/joomlashine/css/jsn-gui.css'));
     $redirAfterFinish = 'index.php?option=com_poweradmin&view=about';
     $this->assign('redirAfterFinish', $redirAfterFinish);
     // Display the template
     parent::display($tpl);
 }
コード例 #28
0
ファイル: view.php プロジェクト: jdrzaic/joomla-dummy
 /**
  * Constructor
  *
  * @param   array  $config  A named configuration array for object construction.
  */
 public function __construct($config = array())
 {
     // Display only the component output
     JFactory::getApplication()->input->def('tmpl', 'component');
     parent::__construct($config);
     // Load category model
     $model = JSNBaseModel::getInstance('Categories', 'CategoriesModel');
     $this->setModel($model, true);
     // Include the component HTML helpers
     $this->addTemplatePath(dirname(__FILE__) . '/tmpl');
     JHtml::addIncludePath(JPATH_COMPONENT . '/helpers/html');
     // Load assets
     JSNBaseHelper::loadAssets();
     echo JSNHtmlAsset::loadScript('jsn/selectorFilter', array(), true);
 }
コード例 #29
0
 /**
  * Fetches the button HTML code.
  *
  * @param   string   $type       Unused string.
  * @param   string   $ref        The name of the help screen (its key reference).
  * @param   boolean  $com        Use the help file in the component directory.
  * @param   string   $override   Use this URL instead of any other.
  * @param   string   $component  Name of component to get Help (null for current component)
  *
  * @return  string
  *
  * @since   2.5
  */
 public function fetchButton($type = 'JSNHelpButton', $name = '', $text = '', $url = '', $width = 640, $height = 480, $top = 0, $left = 0, $onClose = '')
 {
     //JHTML::_('behavior.modal', 'a.jsn-is-helper-modal');
     JSNHtmlAsset::loadScript('imageshow/joomlashine/help', array('pathRoot' => JURI::root(), 'language' => JSNUtilsLanguage::getTranslated(array('JSN_IMAGESHOW_OK', 'JSN_IMAGESHOW_CLOSE', 'JSN_IMAGESHOW_SAVE', 'JSN_IMAGESHOW_CANCEL'))));
     $text = JText::_('JTOOLBAR_HELP');
     $class = $this->fetchIconClass('help');
     $doTask = $this->_getCommand($name, $url, $width, $height, $top, $left);
     //$html = "<a href=\"#\" rel='{\"size\": {\"x\": 500, \"y\": 350}}' class=\"toolbar jsn-is-modal\">\n";
     $html = "<a class=\"jsn-is-helper-modal\" href=\"javascript: void(0);\">\n";
     $html .= "<span class=\"{$class}\">\n";
     $html .= "</span>\n";
     $html .= "{$text}\n";
     $html .= "</a>\n";
     return $html;
 }
コード例 #30
0
ファイル: view.html.php プロジェクト: NallelyFlores89/basvec
 public function display($tpl = null)
 {
     $app = JFactory::getApplication();
     $document = JFactory::getDocument();
     $positionName = JRequest::getVar('positionname', '');
     JSNHtmlAsset::addScript(JURI::root(true) . '/media/jui/js/jquery.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.jquery.noconflict.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.functions.js');
     JSNHtmlAsset::addScript(JSN_POWERADMIN_LIB_JSNJS_URI . 'jsn.filter.visualmode.js');
     //Enable position filter.
     $this->setFilterable(true);
     $customScript = "\n\t\t\tvar baseUrl  = '" . JURI::root() . "';\n\t\t\t(function (\$){\n\t\t\t\t\$(document).ready(function (){\n\t\t\t\t\t\$('#" . $positionName . "-jsnposition').addClass('active-position').attr('title', 'Active position');\n\t\t\t\t});\n\t\t\t})(JoomlaShine.jQuery);\n \t\t";
     $this->addCustomScripts($customScript);
     parent::display($tpl);
 }