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


PHP GlobalConfig::getWebSiteCode方法代码示例

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


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

示例1: Dao

 *
 * @author Speedinfo SARL
 * @copyright 2003-2012 Speedinfo SARL
 * @contact contact@speedinfo.fr
 * @url http://www.speedinfo.fr
 *
 */
/* Loading classes */
if (file_exists(dirname(__FILE__) . '/dao.class.php')) {
    include_once 'dao.class.php';
}
if (file_exists(dirname(__FILE__) . '/postActionRequest.class.php')) {
    include_once 'postActionRequest.class.php';
}
$dao = new Dao();
$postOSIReq = new PostActionRequests(GlobalConfig::getWsUrl(), GlobalConfig::getWsPort(), 20, GlobalConfig::getWsLogin(), GlobalConfig::getWsPasswd(), GlobalConfig::getServiceCode(), GlobalConfig::getWebSiteCode());
/* WebService infos values */
$wSOInfosList = Scheduler::getWsInfosList();
/* POST requests */
if (ForceRequest::isForcedRequest()) {
    /* Send only one POST request */
    $wsName = ForceRequest::getWsName();
    $dateFrom = ForceRequest::getDateFrom() . " " . ForceRequest::getTimeFrom();
    $dateFrom = date::dateTimeFr2DateTimeBdd($dateFrom);
    $dateTo = ForceRequest::getDateTo() . " " . ForceRequest::getTimeTo();
    $dateTo = date::dateTimeFr2DateTimeBdd($dateTo);
    doPostSynch($wsName, $dateFrom, $dateTo);
} else {
    /* Send all POST requests in function of the scheduler permissions */
    $wSOList = Scheduler::getWsNamePostList();
    foreach ($wSOList as $wsName) {
开发者ID:rtajmahal,项目名称:PrestaShop-modules,代码行数:31,代码来源:postSynchCtrl.php

示例2: _displayInformations

    private function _displayInformations()
    {
        $html = '';
        /* Get configuration */
        $urlws = Configuration::get('OSI_WS_URL');
        $portws = Configuration::get('OSI_WS_PORT');
        $loginws = Configuration::get('OSI_WS_LOGIN');
        $passwdws = Configuration::get('OSI_WS_PASSWD');
        $servicecode = Configuration::get('OSI_SERVICE_CODE');
        $websitecode = Configuration::get('OSI_WEBSITE_CODE');
        $depotcode = Configuration::get('OSI_DEPOSIT_CODE');
        if ($urlws == '' || $portws == '' || $loginws == '' || $passwdws == '' || $servicecode == '' || $websitecode == '' || $depotcode == '') {
            $html .= '<div class="error_box">' . $this->l('The webservice access OpenSi and the cron must be configured.');
            $html .= '<br />';
            $html .= $this->l('Absolute path to specify in your crontab') . ' : sh ' . dirname(__FILE__) . '/cron.sh</div>';
        }
        $html .= '
			<fieldset>
				<legend><img src="' . $this->_path . 'img/access.png" alt="" />' . $this->l('Access configuration') . '</legend>
				<label>' . $this->l('Login') . ' <sup>*</sup></label>
				<div class="margin-form">
					<input type="text" name="osi_ws_login" class="biginp" value="' . Tools::htmlentitiesUTF8(GlobalConfig::getWsLogin()) . '" />
				</div>	
				<label>' . $this->l('Password') . ' <sup>*</sup></label>
				<div class="margin-form">
					<input type="password" name="osi_ws_passwd" class="biginp" value="' . Tools::htmlentitiesUTF8(GlobalConfig::getWsPasswd()) . '" />
				</div>
				<label>' . $this->l('Service code') . ' <sup>*</sup></label>
				<div class="margin-form">
					<input type="text" name="osi_service_code" class="biginp" value="' . Tools::htmlentitiesUTF8(GlobalConfig::getServiceCode()) . '" />
				</div>
				<label>' . $this->l('website code') . ' <sup>*</sup></label>
				<div class="margin-form">
					<input type="text" name="osi_website_code" class="biginp" value="' . Tools::htmlentitiesUTF8(GlobalConfig::getWebSiteCode()) . '" />
				</div>
				<label>' . $this->l('deposit code') . ' <sup>*</sup></label>
				<div class="margin-form">
					<input type="text" name="osi_deposit_code" class="biginp" value="' . Tools::htmlentitiesUTF8(GlobalConfig::getDepositCode()) . '" />
				</div>																		
			</fieldset>

			<br /><br />

			<fieldset>
				<legend><img src="' . $this->_path . 'img/cron.png" alt="" />' . $this->l('Cron configuration') . '</legend>
				<strong>D&eacute;finition</strong> : Le cron est un s&eacute;quenceur de t&acirc;ches syst&egrave;me UNIX.<br />
				<u>Son activation est n&eacute;cessaire</u> pour automatiser les flux (commandes, clients, stocks, prix, ...) entre OpenSi et votre boutique.<br />
				Pour installer le cron, vous devez proc&eacute;der de la mani&egrave;re suivante :<br /><br />

				<strong>1. Connection &agrave; votre serveur en SSH</strong>
				<div class="cron-details">
					Pour se connecter, ouvrir un terminal et taper la ligne de commande suivante :<br />
					<span class="courier">ssh user@host</span><br />
					<i class="courier">Ex : ssh martin@120.01.02.03</i><br />
					Appuyer sur la touche "entr&eacute;e".<br />
					Rentrer le mot de passe et appuyer &agrave; nouveau sur la touche "entr&eacute;e".<br />
					Vous devez maintenant &ecirc;tre connect&eacute; &agrave; votre serveur.<br /><br />
					<span class="grey">&rarr; L\'&eacute;diteur OpenSi reste &agrave; votre disposition pour vous assister dans <a href="http://www.opensi.fr/Contact_Prestashop.html" class="grey" target="_blank">la mise en place de ce cron</a>.</span>
				</div>

				<strong>2. &Eacute;dition de la crontab</strong>
				<div class="cron-details">
					Pour &eacute;diter la crontab, taper la ligne de commande suivante :<br />
					<span class="courier">crontab -e</span><br />
					et appuyer sur la touche "entr&eacute;e".
				</div>

				<strong>3. Configuration de la crontab</strong>
				<div class="cron-details">
					Ajouter la ligne suivante dans votre crontab, enregistrer et fermer le fichier.<br />
					<span class="courier">*/10 * * * * sh ' . dirname(__FILE__) . '/cron.sh</span>
				</div>

				Votre crontab est maintenant configur&eacute;e.
			</fieldset>

			<br /><br />

			<fieldset>
				<legend><img src="' . $this->_path . 'img/parameters.png" alt="" />' . $this->l('OpenSi adminnistration') . '</legend>
				<span class="mini brown"><img src="' . $this->_path . 'img/warning.png" alt="" />' . $this->l('Do not change the value of the fields below.') . '</span><br /><br />
				<label>' . $this->l('Url') . ' <sup>*</sup></label>
				<div class="margin-form">
					<input type="text" name="osi_ws_url" class="biginp" id="ws_url" value="' . Tools::htmlentitiesUTF8(GlobalConfig::getWsUrl()) . '" />
				</div>
				<label>' . $this->l('Port') . ' <sup>*</sup></label>
				<div class="margin-form">
					<input type="text" name="osi_ws_port" class="biginp" value="' . Tools::htmlentitiesUTF8(GlobalConfig::getWsPort()) . '" />
				</div>
			</fieldset>
		';
        return $html;
    }
开发者ID:rtajmahal,项目名称:PrestaShop-modules,代码行数:93,代码来源:opensi.php

示例3: createPublicationProductXml

 public static function createPublicationProductXml($product)
 {
     $docXml = self::createResponseXml();
     $request = $docXml->createElement("request");
     $publicationElem = $docXml->createElement("Pubweb_Article");
     $publicationElem->setAttribute('Code_Site_Web', GlobalConfig::getWebSiteCode());
     $publicationElem->setAttribute('Reference', $product['reference']);
     $isActivated = $product['active'] == 1 ? "true" : "false";
     $publicationElem->setAttribute('Publication', $isActivated);
     $request->appendChild($publicationElem);
     $docXml->appendChild($request);
     return $docXml->saveXML();
 }
开发者ID:rtajmahal,项目名称:PrestaShop-modules,代码行数:13,代码来源:xml.class.php


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