<?php /** * @package JKit * @copyright Copyright (C) CloudHotelier. All rights reserved. * @license GNU GPLv2 <http://www.gnu.org/licenses/gpl.html> * @author Xavier Pallicer <*****@*****.**> */ defined('_JEXEC') or die; // load assets CHAssets::uikit_component('grid'); CHAssets::uikit_component('lightbox'); CHAssets::uikit_component('slidenav'); CHAssets::script('jkit', 'jkit.min.js'); CHAssets::style('jkit', 'jkit.min.css'); // images $path_images = JURI::root() . 'images/jkit/images/'; // subheading $subheading = $this->params->get('subheading') ? ' <small>' . $this->escape($this->params->get('subheading')) . '</small>' : ''; ?> <!-- view --> <div class="jkit-view-gallery" data-jkit="gallery"> <!-- title --> <?php if ($this->data->title_show) { ?> <h1 class="uk-heading-large"><?php echo $this->data->title . $subheading; ?>
/** * Load required assets */ static function chassets() { // check if already loaded $app = self::getApp(); if (isset($app->chclient->assets)) { return; } // config $config = self::getConfig(); // chclient assets CHAssets::script('chclient', 'chclient.min.js'); CHAssets::style('chclient', 'chclient.min.css'); // credit card validator CHAssets::script('chclient/jquery-creditcardvalidator', 'jquery.creditCardValidator.min.js'); // required uikit components CHAssets::uikit_component('accordion'); CHAssets::uikit_component('datepicker'); CHAssets::uikit_component('form-select'); CHAssets::uikit_component('notify'); CHAssets::uikit_component('sticky'); CHAssets::uikit_component('tooltip'); // optional components if ($config->settings_uikit_form_advanced) { CHAssets::uikit_component('form-advanced'); } // javascript options $localeconv = CHLibDisplay::getLocaleconv(); $js = (object) []; $js->string_error = self::string('error_occurred'); $js->string_check_form = self::string('error_check_form'); $js->string_people = self::string('people'); $js->money_decimal = $localeconv['mon_decimal_point']; $js->money_thousands = $localeconv['mon_thousands_sep']; $js->datepicker_i18n = self::datePickerLocale(); $js->datepicker_min_date = CHLibDate::getDate()->format(CHLibDate::dateLocale()); $js->datepicker_format = str_replace('Y', 'YYYY', str_replace('m', 'MM', str_replace('d', 'DD', CHLibDate::dateLocale()))); $js->datepicker_weekstart = CHLibDate::weekStart(); $js->bootstrap_adapter = (int) $config->settings_bootstrap_adapter; CHAssets::script_declaration('window.chclient_options = ' . json_encode($js) . ';'); $app->chclient->assets = true; }