当前位置: 首页>>代码示例>>PHP>>正文


PHP Configuration::get方法代码示例

本文整理汇总了PHP中Configuration::get方法的典型用法代码示例。如果您正苦于以下问题:PHP Configuration::get方法的具体用法?PHP Configuration::get怎么用?PHP Configuration::get使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Configuration的用法示例。


在下文中一共展示了Configuration::get方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: getTranslationsFieldsChild

 /**
  * Check then return multilingual fields for database interaction
  *
  * @return array Multilingual fields
  */
 public function getTranslationsFieldsChild()
 {
     parent::validateFieldsLang();
     $fieldsArray = array('title', 'url');
     $fields = array();
     $languages = Language::getLanguages(false);
     $defaultLanguage = (int) Configuration::get('PS_LANG_DEFAULT');
     foreach ($languages as $language) {
         $fields[$language['id_lang']]['id_lang'] = (int) $language['id_lang'];
         $fields[$language['id_lang']][self::$definition['primary']] = (int) $this->id;
         foreach ($fieldsArray as $field) {
             if (!Validate::isTableOrIdentifier($field)) {
                 die(Tools::displayError());
             }
             if (isset($this->{$field}[$language['id_lang']]) and !empty($this->{$field}[$language['id_lang']])) {
                 $fields[$language['id_lang']][$field] = pSQL($this->{$field}[$language['id_lang']], true);
             } elseif (in_array($field, $this->fieldsRequiredLang)) {
                 $fields[$language['id_lang']][$field] = pSQL($this->{$field}[$defaultLanguage], true);
             } else {
                 $fields[$language['id_lang']][$field] = '';
             }
         }
     }
     return $fields;
 }
开发者ID:arozanski,项目名称:simpleresponsivetheme,代码行数:30,代码来源:ResponsiveLinksClass.php

示例2: __construct

 public function __construct()
 {
     parent::__construct();
     $this->opo_app_config = Configuration::load();
     $vs_external_app_config_path = $this->opo_app_config->get('external_applications');
     $this->opo_external_app_config = Configuration::load($vs_external_app_config_path);
 }
开发者ID:samrahman,项目名称:providence,代码行数:7,代码来源:BaseMediaPlugin.php

示例3: loadClass

 public function loadClass($class)
 {
     // Enable PSR-4 style namespace support.
     $class = str_replace('\\', DIRECTORY_SEPARATOR, $class);
     if (substr($class, -10) == 'Controller') {
         // This is a controller class file.
         $filename = "{$this->controllerPath}/{$class}.class.php";
     } else {
         if (substr($class, -4) == 'Form') {
             // This is a form class file.
             $filename = "{$this->applicationPath}/forms/{$class}.class.php";
         } elseif (substr($class, -5) == 'Model') {
             // This is a model class file.
             $filename = "{$this->applicationPath}/models/{$class}.class.php";
         } else {
             // This is an application class file (outside of MVC).
             $filename = "{$this->applicationPath}/classes/{$class}.class.php";
         }
     }
     if (file_exists($filename) == true) {
         /** @noinspection PhpIncludeInspection */
         include $filename;
     } else {
         if ($this->configuration->get('library', 'autoload-chain', false) == false) {
             throw new ErrorException("La classe <strong>{$class}</strong> ne se trouve pas " . "dans le fichier<br><strong>{$filename}</strong>");
         }
     }
 }
开发者ID:paolocl,项目名称:ChezPaolo,代码行数:28,代码来源:MicroKernel.class.php

示例4: connect

 /**
  * connection using the injected config
  */
 public function connect()
 {
     $host = $this->configuration->get('host');
     // connection to host, authentication etc...
     //if connected
     $this->host = $host;
 }
开发者ID:boiler256,项目名称:DesignPatternsPHP,代码行数:10,代码来源:Connection.php

示例5: zcssleedmaker_plugin_setting_bloc

function zcssleedmaker_plugin_setting_bloc(&$myUser)
{
    $configurationManager = new Configuration();
    $configurationManager->getAll();
    $filescss = getCSSMaker();
    $filecss = $configurationManager->get('plugin_cssLeedMaker_css');
    echo '
	<section id="CSSLeedMaker" class="CSSLeedMaker" style="display:none;">
		<form action="action.php?action=zcssleedmaker_update" method="POST">
		<h2>' . _t('P_CSSLEEDMAKER_TITLE') . '</h2>

		<section class="preferenceBloc">
			<h3>' . _t('P_CSSLEEDMAKER_DEFAULT_FILE') . '</h3>
			<select name="plugin_cssLeedMaker_css" id="plugin_cssLeedMaker_css">
				<option value="none">' . _t('P_CSSLEEDMAKER_NONE') . '</option>';
    foreach ($filescss as $file) {
        if ($file != ".htaccess" && $file != "@eadir" && $file != ".DS_Store") {
            if ($file == $filecss) {
                echo '<option selected="selected" value="' . $file . '">' . $file . '</option>';
            } else {
                echo '<option value="' . $file . '">' . $file . '</option>';
            }
        }
    }
    echo '	</select>
			<h3>' . _t('P_CSSLEEDMAKER_ADD_CSS_PERSO') . '</h3>
			<textarea name="plugin_cssLeedMaker_addcss" rows=20 cols=40 wrap=physical>' . rawurldecode($configurationManager->get('plugin_cssLeedMaker_addcss')) . '</textarea>
		</section>
		<input type="submit" class="button" value="' . _t('P_CSSLEEDMAKER_BTN_SAVE') . '">
		</form>
		
		<p>' . _t('P_CSSLEEDMAKER_COMMENT_AUTHOR') . '</p>
	</section>
	';
}
开发者ID:kraoc,项目名称:Leed-market,代码行数:35,代码来源:z_cssLeedMaker.plugin.disabled.php

示例6: __construct

 /**
  * Mapping constructor.
  */
 public function __construct()
 {
     // set up basic properties
     $this->opo_datamodel = \Datamodel::load();
     $this->opo_search_conf = \Configuration::load(\Configuration::load()->get('search_config'));
     $this->opo_indexing_conf = \Configuration::load($this->opo_search_conf->get('search_indexing_config'));
     $this->opo_db = new \Db();
     $this->opo_search_base = new \SearchBase($this->opo_db, null, false);
     $this->opa_element_info = array();
     $this->opo_app_vars = new \ApplicationVars($this->opo_db);
     $this->prefetchElementInfo();
 }
开发者ID:samrahman,项目名称:providence,代码行数:15,代码来源:Mapping.php

示例7: hookCreateAccountTop

 public function hookCreateAccountTop($params)
 {
     global $smarty;
     $tag = '<img src=' . (Configuration::get('PS_SSL_ENABLED') ? 'https://' : 'http://') . 'api.reversoform.com/includes/' . (Configuration::get('PS_SSL_ENABLED') ? 'www.reversoform.com/' : '') . 'js/trans.giff?d=' . date('U') . ' with="0" height="0" />';
     $smarty->assign(array('reverso_tag' => $tag));
     return $this->display(__FILE__, 'reverso.tpl');
 }
开发者ID:priyankajsr19,项目名称:indusdiva2,代码行数:7,代码来源:reverso.php

示例8: __construct

 /**
  * The Symphony constructor initialises the class variables of Symphony.
  * It will set the DateTime settings, define new date constants and initialise
  * the correct Language for the currently logged in Author. If magic quotes
  * are enabled, Symphony will sanitize the `$_SERVER`, `$_COOKIE`,
  * `$_GET` and `$_POST` arrays. The constructor loads in
  * the initial Configuration values from the `CONFIG` file
  */
 protected function __construct()
 {
     self::$Profiler = Profiler::instance();
     self::$Profiler->sample('Engine Initialisation');
     if (get_magic_quotes_gpc()) {
         General::cleanArray($_SERVER);
         General::cleanArray($_COOKIE);
         General::cleanArray($_GET);
         General::cleanArray($_POST);
     }
     $this->initialiseConfiguration();
     define_safe('__SYM_DATE_FORMAT__', self::Configuration()->get('date_format', 'region'));
     define_safe('__SYM_TIME_FORMAT__', self::Configuration()->get('time_format', 'region'));
     define_safe('__SYM_DATETIME_FORMAT__', __SYM_DATE_FORMAT__ . self::Configuration()->get('datetime_separator', 'region') . __SYM_TIME_FORMAT__);
     DateTimeObj::setSettings(self::Configuration()->get('region'));
     // Initialize language management
     Lang::initialize();
     $this->initialiseLog();
     GenericExceptionHandler::initialise(self::Log());
     GenericErrorHandler::initialise(self::Log());
     $this->initialiseDatabase();
     $this->initialiseExtensionManager();
     $this->initialiseCookie();
     // If the user is not a logged in Author, turn off the verbose error messages.
     if (!self::isLoggedIn() && is_null($this->Author)) {
         GenericExceptionHandler::$enabled = false;
     }
     // Set system language
     Lang::set(self::$Configuration->get('lang', 'symphony'));
 }
开发者ID:readona,项目名称:symphonyno5,代码行数:38,代码来源:class.symphony.php

示例9: initContent

 public function initContent()
 {
     if (Configuration::get('PS_DISPLAY_BEST_SELLERS')) {
         parent::initContent();
         $this->productSort();
         $nb_products = (int) ProductSale::getNbSales();
         $this->pagination($nb_products);
         if (!Tools::getValue('orderby')) {
             $this->orderBy = 'sales';
         }
         $products = ProductSale::getBestSales($this->context->language->id, $this->p - 1, $this->n, $this->orderBy, $this->orderWay);
         $this->addColorsToProductList($products);
         /************************* /Images Array ******************************/
         if (method_exists('Product', 'getProductsImgs')) {
             $image_array = array();
             for ($i = 0; $i < $nb_products; $i++) {
                 if (isset($products[$i]['id_product'])) {
                     $image_array[$products[$i]['id_product']] = Product::getProductsImgs($products[$i]['id_product']);
                 }
             }
             $this->context->smarty->assign('productimg', (isset($image_array) and $image_array) ? $image_array : NULL);
         }
         /************************* /Images Array ******************************/
         $this->context->smarty->assign(array('products' => $products, 'add_prod_display' => Configuration::get('PS_ATTRIBUTE_CATEGORY_DISPLAY'), 'nbProducts' => $nb_products, 'homeSize' => Image::getSize(ImageType::getFormatedName('home')), 'comparator_max_item' => Configuration::get('PS_COMPARATOR_MAX_ITEM')));
         $this->setTemplate(_PS_THEME_DIR_ . 'best-sales.tpl');
     } else {
         Tools::redirect('index.php?controller=404');
     }
 }
开发者ID:evgrishin,项目名称:se1614,代码行数:29,代码来源:BestSalesController.php

示例10: renderForm

 public function renderForm($args, $data)
 {
     # validate module
     unset($args);
     $this->checkFolderImage();
     $helper = $this->getFormHelper();
     $items = '';
     $slide_edit = '';
     if ($data['params'] && isset($data['params']['leoslide']) && $data['params']['leoslide']) {
         $slides = $data['params']['leoslide'];
         $items = $this->getSlide($slides);
         if (Tools::getValue('id_slide')) {
             $id_slide = Tools::getValue('id_slide');
             $slide_edit = $items[$id_slide] ? $items[$id_slide] : '';
         }
     }
     $this->fields_form[1]['form'] = array('legend' => array('title' => $this->l('Carousel Form.')), 'input' => array(array('type' => 'text', 'label' => $this->l('Image Size Width'), 'name' => 'img_width', 'class' => 'fixed-width-xl', 'default' => 1170), array('type' => 'text', 'label' => $this->l('Image size Height'), 'name' => 'img_height', 'class' => 'fixed-width-xl', 'default' => 400), array('type' => 'text', 'label' => $this->l('Thumb Size Width'), 'name' => 'thumb_width', 'class' => 'fixed-width-xl', 'default' => 100), array('type' => 'text', 'label' => $this->l('Thumb size Height'), 'name' => 'thumb_height', 'class' => 'fixed-width-xl', 'default' => 100), array('type' => 'text', 'label' => $this->l('Interval'), 'name' => 'interval', 'class' => 'fixed-width-xl', 'default' => 400, 'desc' => $this->l('Enter Time(miniseconds) to play slide. Value 0 to stop.')), array('type' => 'text', 'label' => $this->l('Transition Speed'), 'name' => 'transitionSpeed', 'class' => 'fixed-width-xl', 'default' => 900, 'desc' => $this->l('Enter Time(miniseconds) to next each slide.')), array('type' => 'select', 'label' => $this->l('Display Progress Bar'), 'name' => 'displayProgressBar', 'default' => '1', 'options' => array('query' => array(array('id' => 1, 'name' => $this->l('Enable')), array('id' => 0, 'name' => $this->l('Disable'))), 'id' => 'id', 'name' => 'name')), array('type' => 'select', 'label' => $this->l('Display Thumbnail Numbers'), 'name' => 'displayThumbnailNumbers', 'default' => '1', 'options' => array('query' => array(array('id' => 1, 'name' => $this->l('Enable')), array('id' => 0, 'name' => $this->l('Disable'))), 'id' => 'id', 'name' => 'name')), array('type' => 'select', 'label' => $this->l('Display Thumbnail Background'), 'name' => 'displayThumbnailBackground', 'default' => '1', 'options' => array('query' => array(array('id' => 1, 'name' => $this->l('Enable')), array('id' => 0, 'name' => $this->l('Disable'))), 'id' => 'id', 'name' => 'name')), array('type' => 'slide', 'name' => 'slide', 'lang' => true, 'selectImg' => Context::getContext()->link->getAdminLink('AdminLeotempcpImages'), 'tree' => '', 'default' => '')), 'buttons' => array(array('title' => $this->l('Save And Stay'), 'icon' => 'process-icon-save', 'class' => 'pull-right', 'type' => 'submit', 'name' => 'saveandstayleotempcp'), array('title' => $this->l('Save'), 'icon' => 'process-icon-save', 'class' => 'pull-right', 'type' => 'submit', 'name' => 'saveleotempcp')));
     $theme_dir = Context::getContext()->shop->theme_directory;
     $images = array();
     $thums = array();
     $images = LeoWidgetBase::getImageList(_PS_ROOT_DIR_ . '/themes/' . $theme_dir . '/img/modules/' . $this->name . '/image');
     $thums = LeoWidgetBase::getImageList(_PS_ROOT_DIR_ . '/themes/' . $theme_dir . '/img/modules/' . $this->name . '/thum');
     $iso = Context::getContext()->language->iso_code;
     $helper->tpl_vars = array('fields_value' => $this->getConfigFieldsValues($data), 'languages' => Context::getContext()->controller->getLanguages(), 'id_lang_default' => Configuration::get('PS_LANG_DEFAULT'), 'iso_code' => Context::getContext()->language->iso_code, 'iso' => file_exists(_PS_CORE_DIR_ . '/js/tiny_mce/langs/' . $iso . '.js') ? $iso : 'en', 'path_css' => _THEME_CSS_DIR_, 'ad' => __PS_BASE_URI__ . basename(_PS_ADMIN_DIR_), 'images' => $images, 'thums' => $thums, 'items' => $items, 'slide_edit' => $slide_edit, 'url' => AdminController::$currentIndex . '&id_leowidgets=' . Tools::getValue('id_leowidgets') . '&updateleowidgets&token=' . Tools::getValue('token') . '&conf=4', 'pathimg' => __PS_BASE_URI__ . 'themes/' . $theme_dir . '/img/modules/' . $this->name . '/image/', 'paththum' => __PS_BASE_URI__ . 'themes/' . $theme_dir . '/img/modules/' . $this->name . '/thum/');
     return $helper->generateForm($this->fields_form);
 }
开发者ID:ahmedonee,项目名称:morinella,代码行数:26,代码来源:fullslider.php

示例11: loadConfig

 public function loadConfig()
 {
     $this->installed = html_entity_decode(Configuration::get('DJL_INSTALLED'), ENT_COMPAT, 'UTF-8');
     $this->useSSL = (int) html_entity_decode(Configuration::get('DJL_USE_SSL'), ENT_COMPAT, 'UTF-8');
     $this->serviceURL = html_entity_decode(Configuration::get('DJL_SERVICE_URL'), ENT_COMPAT, 'UTF-8');
     $this->sandboxServiceURL = html_entity_decode(Configuration::get('DJL_SANDBOX_SERVICE_URL'), ENT_COMPAT, 'UTF-8');
     $this->mode = html_entity_decode(Configuration::get('DJL_MODE'), ENT_COMPAT, 'UTF-8');
     $this->login = html_entity_decode(Configuration::get('DJL_LOGIN'), ENT_COMPAT, 'UTF-8');
     $this->password = html_entity_decode(Configuration::get('DJL_PASSWORD'), ENT_COMPAT, 'UTF-8');
     $this->trigerringStatuses = html_entity_decode(Configuration::get('DJL_TRIGERRING_STATUSES'), ENT_COMPAT, 'UTF-8');
     $this->shippingPrefix = html_entity_decode(Configuration::get('DJL_SHIPPING_PREFIX'), ENT_COMPAT, 'UTF-8');
     $this->country = html_entity_decode(Configuration::get('DJL_COUNTRY'), ENT_COMPAT, 'UTF-8');
     if (strlen($this->country) == 0) {
         $this->country = 'fr';
     }
     $this->visibility_status = html_entity_decode(Configuration::get('DJL_VISIBILITY_STATUS'), ENT_COMPAT, 'UTF-8');
     $this->visible_users_list = html_entity_decode(Configuration::get('DJL_VISIBLE_USERS_LIST'), ENT_COMPAT, 'UTF-8');
     $this->internal_version = Configuration::get('DJL_VERSION');
     // Backward compatibility
     $activeVal = html_entity_decode(Configuration::get('DJL_ACTIVE'), ENT_COMPAT, 'UTF-8');
     if ($activeVal != "") {
         $this->active = (int) $activeVal;
         $this->visibility_status = $this->active == 0 ? "invisible" : "visible";
     }
     if ($this->visibility_status == "") {
         $this->visibility_status = "invisible";
     }
 }
开发者ID:greench,项目名称:prestashop,代码行数:28,代码来源:dejalaconfig.php

示例12: redirect

 public static function redirect($url, $base_uri = __PS_BASE_URI__, Link $link = null, $headers = null)
 {
     if (!$link) {
         $link = Context::getContext()->link;
     }
     if (strpos($url, 'http://') === false && strpos($url, 'https://') === false && $link) {
         if (strpos($url, $base_uri) === 0) {
             $url = substr($url, strlen($base_uri));
         }
         if (strpos($url, 'index.php?controller=') !== false && strpos($url, 'index.php/') == 0) {
             $url = substr($url, strlen('index.php?controller='));
             if (Configuration::get('PS_REWRITING_SETTINGS')) {
                 $url = Tools::strReplaceFirst('&', '?', $url);
             }
         }
         $explode = explode('?', $url);
         // don't use ssl if url is home page
         // used when logout for example
         $use_ssl = !empty($url);
         $url = $link->getPageLink($explode[0], $use_ssl);
         if (isset($explode[1])) {
             $url .= '?' . $explode[1];
         }
     }
     // Send additional headers
     if ($headers) {
         if (!is_array($headers)) {
             $headers = array($headers);
         }
         foreach ($headers as $header) {
             header($header);
         }
     }
     Context::getContext()->controller->setRedirectAfter($url);
 }
开发者ID:M03G,项目名称:PrestaShop,代码行数:35,代码来源:Tools.php

示例13: sds_init_error_warning

 public static function sds_init_error_warning()
 {
     if ((int) Configuration::get('config_maintenance') == 1) {
         echo "<div class='alert alert-warning'>Maintenance mode is enabled. This may cause functional problem at your slider revolution module.</div>";
         if (!in_array(Tools::getRemoteAddr(), explode(',', Configuration::get('PS_MAINTENANCE_IP')))) {
             echo "<div class='alert alert-warning'>It's seemed that your IP is not present in Maintenance IP.</div>";
         }
     }
     if (get_magic_quotes_gpc()) {
         echo "<div class='alert alert-warning'>magic_quotes_gpc is enabled. This may cause functional problem at your slider revolution module. Please disable magic_quotes_gpc.</div>";
     }
     if (get_magic_quotes_runtime()) {
         echo "<div class='alert alert-warning'>magic_quotes_runtime is enabled. This may cause functional problem at your slider revolution module. Please disable magic_quotes_runtime.</div>";
     }
     if (!defined('ABSPATH')) {
         echo "<div class='alert alert-warning'>Fatal Error: 'ABSPATH' isn't defined.</div>";
         return;
     }
     if (!is_writable(ABSPATH . '/uploads')) {
         echo "<div class='alert alert-warning'>'" . ABSPATH . "/uploads' folder is not writeable. Change the folder permission.</div>";
     }
     if (!is_writable(ABSPATH . '/rs-plugin/css')) {
         echo "<div class='alert alert-warning'>'" . ABSPATH . "/rs-plugin/css' folder is not writeable. Change the folder permission.</div>";
     }
     //                    if(!is_executable(ABSPATH.'/rs-plugin/fileuploader/uploadify.php')){
     //                        echo "<div class='alert alert-warning'>'".ABSPATH."/rs-plugin/fileuploader/uploadify.php' file is not executable. Change the file permission.</div>";
     //                    }
     if (!is_writable(ABSPATH . '/cache')) {
         echo "<div class='alert alert-warning'>'" . ABSPATH . "/cache' folder is not writeable. Change the folder permission.</div>";
     }
 }
开发者ID:rinodung,项目名称:opencart-15x-flat-admin,代码行数:31,代码来源:base_admin.class.php

示例14: renderForm

 public function renderForm($args, $data)
 {
     # validate module
     unset($args);
     $this->checkFolderImage();
     $helper = $this->getFormHelper();
     $items = '';
     $slide_edit = '';
     if ($data['params'] && isset($data['params']['leoslide']) && $data['params']['leoslide']) {
         $slides = $data['params']['leoslide'];
         $items = $this->getSlide($slides);
         if (Tools::getValue('id_slide')) {
             $id_slide = Tools::getValue('id_slide');
             $slide_edit = $items[$id_slide] ? $items[$id_slide] : '';
         }
     }
     $this->fields_form[1]['form'] = array('legend' => array('title' => $this->l('Widget Form')), 'input' => array(array('type' => 'html', 'html_content' => 'Please access <a href="http://apollotheme.com/" target="_blank" title="apollo site">Apollotheme.com</a> to buy professional version to use this '), array('type' => 'html', 'html_content' => '<a target="_blank" href="http://apollotheme.com/how-to-buy-pro-version/" target="_blank" title="How to buy">How to buy Professional Version</a>'), array('type' => 'html', 'html_content' => '<a target="_blank" href="http://apollotheme.com/different-between-free-pro-version/" target="_blank" title="Why should use">Why should use Professional Version</a>')), 'buttons' => array(array('title' => $this->l('Save And Stay'), 'icon' => 'process-icon-save', 'class' => 'pull-right', 'type' => 'submit', 'name' => 'saveandstayleotempcp'), array('title' => $this->l('Save'), 'icon' => 'process-icon-save', 'class' => 'pull-right', 'type' => 'submit', 'name' => 'saveleotempcp')));
     $theme_dir = Context::getContext()->shop->theme_directory;
     $images = array();
     $thums = array();
     $images = LeoWidgetBase::getImageList(_PS_ROOT_DIR_ . '/themes/' . $theme_dir . '/img/modules/' . $this->name . '/image');
     $thums = LeoWidgetBase::getImageList(_PS_ROOT_DIR_ . '/themes/' . $theme_dir . '/img/modules/' . $this->name . '/thum');
     $iso = Context::getContext()->language->iso_code;
     $helper->tpl_vars = array('fields_value' => $this->getConfigFieldsValues($data), 'languages' => Context::getContext()->controller->getLanguages(), 'id_lang_default' => Configuration::get('PS_LANG_DEFAULT'), 'iso_code' => Context::getContext()->language->iso_code, 'iso' => file_exists(_PS_CORE_DIR_ . '/js/tiny_mce/langs/' . $iso . '.js') ? $iso : 'en', 'path_css' => _THEME_CSS_DIR_, 'ad' => __PS_BASE_URI__ . basename(_PS_ADMIN_DIR_), 'images' => $images, 'thums' => $thums, 'items' => $items, 'slide_edit' => $slide_edit, 'url' => AdminController::$currentIndex . '&id_leowidgets=' . Tools::getValue('id_leowidgets') . '&updateleowidgets&token=' . Tools::getValue('token') . '&conf=4', 'pathimg' => __PS_BASE_URI__ . 'themes/' . $theme_dir . '/img/modules/' . $this->name . '/image/', 'paththum' => __PS_BASE_URI__ . 'themes/' . $theme_dir . '/img/modules/' . $this->name . '/thum/');
     return $helper->generateForm($this->fields_form);
 }
开发者ID:pacxs,项目名称:pacxscom,代码行数:26,代码来源:fullslider.php

示例15: initContent

 /**
  * @see FrontController::initContent()
  */
 public function initContent()
 {
     parent::initContent();
     $shop_name = htmlentities(Configuration::get('PS_SHOP_NAME'), NULL, 'utf-8');
     $shop_url = Tools::getHttpHost(true, true);
     $customer = Context::getContext()->customer;
     if (!preg_match("#.*\\.html\$#Ui", Tools::getValue('mail')) or !preg_match("#.*\\.html\$#Ui", Tools::getValue('mail'))) {
         die(Tools::redirect());
     }
     $file = file_get_contents(dirname(__FILE__) . '/../../mails/' . strval(preg_replace('#\\.{2,}#', '.', Tools::getValue('mail'))));
     $file = str_replace('{shop_name}', $shop_name, $file);
     $file = str_replace('{shop_url}', $shop_url . __PS_BASE_URI__, $file);
     $file = str_replace('{shop_logo}', $shop_url . _PS_IMG_ . 'logo.jpg', $file);
     $file = str_replace('{firstname}', $customer->firstname, $file);
     $file = str_replace('{lastname}', $customer->lastname, $file);
     $file = str_replace('{email}', $customer->email, $file);
     $file = str_replace('{firstname_friend}', 'XXXXX', $file);
     $file = str_replace('{lastname_friend}', 'xxxxxx', $file);
     $file = str_replace('{link}', 'authentication.php?create_account=1', $file);
     $discount_type = (int) Configuration::get('REFERRAL_DISCOUNT_TYPE');
     if ($discount_type == 1) {
         $file = str_replace('{discount}', Discount::display((double) Configuration::get('REFERRAL_PERCENTAGE'), $discount_type, new Currency($this->context->currency->id)), $file);
     } else {
         $file = str_replace('{discount}', Discount::display((double) Configuration::get('REFERRAL_DISCOUNT_VALUE_' . $this->context->currency->id), $discount_type, new Currency($this->context->currency->id)), $file);
     }
     $this->context->smarty->assign(array('content' => $file));
     $this->setTemplate('email.tpl');
 }
开发者ID:jicheng17,项目名称:vipinsg,代码行数:31,代码来源:email.php


注:本文中的Configuration::get方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。