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


PHP plxUtils::cdataCheck方法代码示例

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


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

示例1: step1

 public function step1()
 {
     echo L_UPDATE_USERS_MIGRATION . "<br />";
     # On génère le fichier XML
     $xml = "<?xml version=\"1.0\" encoding=\"" . PLX_CHARSET . "\"?>\n";
     $xml .= "<document>\n";
     foreach ($this->plxAdmin->aUsers as $user_id => $user) {
         $salt = plxUtils::charAleatoire(10);
         $password = sha1($salt . $user['password']);
         $xml .= "\t" . '<user number="' . $user_id . '" active="' . $user['active'] . '" profil="' . $user['profil'] . '" delete="' . $user['delete'] . '">' . "\n";
         $xml .= "\t\t" . '<login><![CDATA[' . plxUtils::cdataCheck($user['login']) . ']]></login>' . "\n";
         $xml .= "\t\t" . '<name><![CDATA[' . plxUtils::cdataCheck($user['name']) . ']]></name>' . "\n";
         $xml .= "\t\t" . '<infos><![CDATA[' . plxUtils::cdataCheck($user['infos']) . ']]></infos>' . "\n";
         $xml .= "\t\t" . '<password><![CDATA[' . $password . ']]></password>' . "\n";
         $xml .= "\t\t" . '<salt><![CDATA[' . $salt . ']]></salt>' . "\n";
         $xml .= "\t\t" . '<email><![CDATA[' . $user['email'] . ']]></email>' . "\n";
         $xml .= "\t\t" . '<lang><![CDATA[' . $user['lang'] . ']]></lang>' . "\n";
         $xml .= "\t</user>\n";
     }
     $xml .= "</document>";
     if (!plxUtils::write($xml, PLX_ROOT . $this->plxAdmin->aConf['users'])) {
         echo '<p class="error">' . L_UPDATE_ERR_USERS_MIGRATION . ' (' . $this->plxAdmin->aConf['users'] . ')</p>';
         return false;
     }
     return true;
 }
开发者ID:wafflefactor,项目名称:PluXml,代码行数:26,代码来源:update_5.1.1.php

示例2: saveParams

 /**
  * Méthode qui sauvegarde le fichier des parametres du plugin parameters.xml
  *
  * @return	boolean		resultat de la sauvegarde / TRUE = ok
  * @author	Stephane F
  **/
 public function saveParams()
 {
     # Début du fichier XML
     $xml = "<?xml version='1.0' encoding='" . PLX_CHARSET . "'?>\n";
     $xml .= "<document>\n";
     foreach ($this->aParams as $k => $v) {
         switch ($v['type']) {
             case 'numeric':
                 $xml .= "\t<parameter name=\"{$k}\" type=\"" . $v['type'] . "\">" . intval($v['value']) . "</parameter>\n";
                 break;
             case 'string':
                 $xml .= "\t<parameter name=\"{$k}\" type=\"" . $v['type'] . "\">" . plxUtils::cdataCheck(plxUtils::strCheck($v['value'])) . "</parameter>\n";
                 break;
             case 'cdata':
                 $xml .= "\t<parameter name=\"{$k}\" type=\"" . $v['type'] . "\"><![CDATA[" . plxUtils::cdataCheck($v['value']) . "]]></parameter>\n";
                 break;
         }
     }
     $xml .= "</document>";
     # On écrit le fichier
     if (plxUtils::write($xml, $this->plug['parameters.xml'])) {
         # suppression ancien fichier parameters.xml s'il existe encore (5.1.7+)
         if (file_exists($this->plug['dir'] . $this->plug['name'] . '/parameters.xml')) {
             unlink($this->plug['dir'] . $this->plug['name'] . '/parameters.xml');
         }
         return plxMsg::Info(L_SAVE_SUCCESSFUL);
     } else {
         return plxMsg::Error(L_SAVE_ERR . ' ' . $this->plug['parameters.xml']);
     }
 }
开发者ID:wafflefactor,项目名称:PluXml,代码行数:36,代码来源:class.plx.plugins.php

示例3: install

function install($content, $config)
{
    # gestion du timezone
    date_default_timezone_set($config['timezone']);
    # Création du fichier de configuration
    $xml = '<?xml version="1.0" encoding="' . PLX_CHARSET . '"?>' . "\n";
    $xml .= '<document>' . "\n";
    foreach ($config as $k => $v) {
        if (is_numeric($v)) {
            $xml .= "\t<parametre name=\"{$k}\">" . $v . "</parametre>\n";
        } else {
            $xml .= "\t<parametre name=\"{$k}\"><![CDATA[" . plxUtils::cdataCheck($v) . "]]></parametre>\n";
        }
    }
    $xml .= '</document>';
    plxUtils::write($xml, path('XMLFILE_PARAMETERS'));
    # Création du fichier des utilisateurs
    $salt = plxUtils::charAleatoire(10);
    $xml = '<?xml version="1.0" encoding="' . PLX_CHARSET . '"?>' . "\n";
    $xml .= "<document>\n";
    $xml .= "\t" . '<user number="001" active="1" profil="0" delete="0">' . "\n";
    $xml .= "\t\t" . '<login><![CDATA[' . trim($content['login']) . ']]></login>' . "\n";
    $xml .= "\t\t" . '<name><![CDATA[' . trim($content['name']) . ']]></name>' . "\n";
    $xml .= "\t\t" . '<infos><![CDATA[]]></infos>' . "\n";
    $xml .= "\t\t" . '<password><![CDATA[' . sha1($salt . md5(trim($content['pwd']))) . ']]></password>' . "\n";
    $xml .= "\t\t" . '<salt><![CDATA[' . $salt . ']]></salt>' . "\n";
    $xml .= "\t\t" . '<email><![CDATA[]]></email>' . "\n";
    $xml .= "\t\t" . '<lang><![CDATA[' . $config['default_lang'] . ']]></lang>' . "\n";
    $xml .= "\t</user>\n";
    $xml .= "</document>";
    plxUtils::write($xml, path('XMLFILE_USERS'));
    # Création du fichier des categories
    $xml = '<?xml version="1.0" encoding="' . PLX_CHARSET . '"?>' . "\n";
    $xml .= '<document>' . "\n";
    $xml .= "\t" . '<categorie number="001" active="1" homepage="1" tri="' . $config['tri'] . '" bypage="' . $config['bypage'] . '" menu="oui" url="' . L_DEFAULT_CATEGORY_URL . '" template="categorie.php"><name><![CDATA[' . plxUtils::strRevCheck(L_DEFAULT_CATEGORY_TITLE) . ']]></name><description><![CDATA[]]></description><meta_description><![CDATA[]]></meta_description><meta_keywords><![CDATA[]]></meta_keywords><title_htmltag><![CDATA[]]></title_htmltag></categorie>' . "\n";
    $xml .= '</document>';
    plxUtils::write($xml, path('XMLFILE_CATEGORIES'));
    # Création du fichier des pages statiques
    $xml = '<?xml version="1.0" encoding="' . PLX_CHARSET . '"?>' . "\n";
    $xml .= '<document>' . "\n";
    $xml .= "\t" . '<statique number="001" active="1" menu="oui" url="' . L_DEFAULT_STATIC_URL . '" template="static.php"><group><![CDATA[]]></group><name><![CDATA[' . plxUtils::strRevCheck(L_DEFAULT_STATIC_TITLE) . ']]></name><meta_description><![CDATA[]]></meta_description><meta_keywords><![CDATA[]]></meta_keywords><title_htmltag><![CDATA[]]></title_htmltag></statique>' . "\n";
    $xml .= '</document>';
    plxUtils::write($xml, path('XMLFILE_STATICS'));
    plxUtils::write(file_get_contents(PLX_CORE . '/lib/html.static.txt'), PLX_ROOT . $config['racine_statiques'] . '001.' . L_DEFAULT_STATIC_URL . '.php');
    # Création du premier article
    $html = explode('-----', file_get_contents(PLX_CORE . '/lib/html.article.txt'));
    $xml = '<?xml version="1.0" encoding="' . PLX_CHARSET . '"?>' . "\n";
    $xml .= '<document>
	<title><![CDATA[' . plxUtils::strRevCheck(L_DEFAULT_ARTICLE_TITLE) . ']]></title>
	<allow_com>1</allow_com>
	<template><![CDATA[article.php]]></template>
	<chapo>
		<![CDATA[' . $html[0] . ']]>
	</chapo>
	<content>
		<![CDATA[' . $html[1] . ']]>
	</content>
	<tags>
		<![CDATA[PluXml]]>
	</tags>
	<meta_description>
		<![CDATA[]]>
	</meta_description>
	<meta_keywords>
		<![CDATA[]]>
	</meta_keywords>
	<title_htmltag>
		<![CDATA[]]>
	</title_htmltag>
</document>';
    plxUtils::write($xml, PLX_ROOT . $config['racine_articles'] . '0001.001.001.' . date('YmdHi') . '.' . L_DEFAULT_ARTICLE_URL . '.xml');
    # Création du fichier des tags servant de cache
    $xml = '<?xml version="1.0" encoding="' . PLX_CHARSET . '"?>' . "\n";
    $xml .= '<document>' . "\n";
    $xml .= "\t" . '<article number="0001" date="' . date('YmdHi') . '" active="1"><![CDATA[PluXml]]></article>' . "\n";
    $xml .= '</document>';
    plxUtils::write($xml, path('XMLFILE_TAGS'));
    # Création du fichier des plugins
    $xml = '<?xml version="1.0" encoding="' . PLX_CHARSET . '"?>' . "\n";
    $xml .= '<document>' . "\n";
    $xml .= '</document>';
    plxUtils::write($xml, path('XMLFILE_PLUGINS'));
    # Création du premier commentaire
    $xml = '<?xml version="1.0" encoding="' . PLX_CHARSET . '"?>' . "\n";
    $xml .= '<comment>
	<author><![CDATA[pluxml]]></author>
		<type>normal</type>
		<ip>127.0.0.1</ip>
		<mail><![CDATA[contact@pluxml.org]]></mail>
		<site><![CDATA[http://www.pluxml.org]]></site>
		<content><![CDATA[' . plxUtils::strRevCheck(L_DEFAULT_COMMENT_CONTENT) . ']]></content>
	</comment>';
    plxUtils::write($xml, PLX_ROOT . $config['racine_commentaires'] . '0001.' . date('U') . '-1.xml');
}
开发者ID:vovd,项目名称:PluXml,代码行数:94,代码来源:install.php

示例4: editTags

 /**
  * Méthode qui sauvegarde la liste des tags dans fichier XML
  * selon le contenu de la variable de classe $aTags
  *
  * @param	null
  * @return	null
  * @author	Stephane F
  **/
 public function editTags()
 {
     # Génération du fichier XML
     $xml = "<?xml version='1.0' encoding='" . PLX_CHARSET . "'?>\n";
     $xml .= "<document>\n";
     foreach ($this->aTags as $id => $tag) {
         $xml .= "\t" . '<article number="' . $id . '" date="' . $tag['date'] . '" active="' . $tag['active'] . '"><![CDATA[' . plxUtils::cdataCheck($tag['tags']) . ']]></article>' . "\n";
     }
     $xml .= "</document>";
     # On écrit le fichier
     plxUtils::write($xml, path('XMLFILE_TAGS'));
 }
开发者ID:wafflefactor,项目名称:PluXml,代码行数:20,代码来源:class.plx.admin.php

示例5: step5

 public function step5()
 {
     echo L_UPDATE_USERS_MIGRATION . "<br />";
     if ($users = $this->_getUsers(PLX_ROOT . $this->plxAdmin->aConf['users'])) {
         # On génère le fichier XML
         $xml = "<?xml version=\"1.0\" encoding=\"" . PLX_CHARSET . "\"?>\n";
         $xml .= "<document>\n";
         foreach ($users as $user_id => $user) {
             if (intval($user['profil'] == '2')) {
                 $user['profil'] = '4';
             }
             $xml .= "\t" . '<user number="' . $user_id . '" active="' . $user['active'] . '" profil="' . $user['profil'] . '" delete="' . $user['delete'] . '">' . "\n";
             $xml .= "\t\t" . '<login><![CDATA[' . plxUtils::cdataCheck(trim($user['login'])) . ']]></login>' . "\n";
             $xml .= "\t\t" . '<name><![CDATA[' . plxUtils::cdataCheck(trim($user['name'])) . ']]></name>' . "\n";
             $xml .= "\t\t" . '<infos><![CDATA[' . plxUtils::cdataCheck(trim($user['infos'])) . ']]></infos>' . "\n";
             $xml .= "\t\t" . '<password><![CDATA[' . $user['password'] . ']]></password>' . "\n";
             $xml .= "\t\t" . '<email><![CDATA[]]></email>' . "\n";
             $xml .= "\t</user>\n";
         }
         $xml .= "</document>";
         if (!plxUtils::write($xml, PLX_ROOT . $this->plxAdmin->aConf['users'])) {
             echo '<p class="error">' . L_UPDATE_ERR_USERS_MIGRATION . ' (' . $this->plxAdmin->aConf['users'] . ')</p>';
             return false;
         }
     }
     return true;
 }
开发者ID:wafflefactor,项目名称:PluXml,代码行数:27,代码来源:update_5.1.php

示例6: addCommentaire

 /**
  * Méthode qui crée physiquement le fichier XML du commentaire
  *
  * @param	comment	array avec les données du commentaire à ajouter
  * @return	booléen
  * @author	Anthony GUÉRIN, Florent MONTHEL et Stéphane F
  **/
 public function addCommentaire($content)
 {
     # Hook plugins
     if (eval($this->plxPlugins->callHook('plxMotorAddCommentaire'))) {
         return;
     }
     # On genere le contenu de notre fichier XML
     $xml = "<?xml version='1.0' encoding='" . PLX_CHARSET . "'?>\n";
     $xml .= "<comment>\n";
     $xml .= "\t<author><![CDATA[" . plxUtils::cdataCheck($content['author']) . "]]></author>\n";
     $xml .= "\t<type>" . $content['type'] . "</type>\n";
     $xml .= "\t<ip>" . $content['ip'] . "</ip>\n";
     $xml .= "\t<mail><![CDATA[" . plxUtils::cdataCheck($content['mail']) . "]]></mail>\n";
     $xml .= "\t<site><![CDATA[" . plxUtils::cdataCheck($content['site']) . "]]></site>\n";
     $xml .= "\t<content><![CDATA[" . plxUtils::cdataCheck($content['content']) . "]]></content>\n";
     $xml .= "\t<parent><![CDATA[" . plxUtils::cdataCheck($content['parent']) . "]]></parent>\n";
     # Hook plugins
     eval($this->plxPlugins->callHook('plxMotorAddCommentaireXml'));
     $xml .= "</comment>\n";
     # On ecrit ce contenu dans notre fichier XML
     return plxUtils::write($xml, PLX_ROOT . $this->aConf['racine_commentaires'] . $content['filename']);
 }
开发者ID:HasClass0,项目名称:PluXml,代码行数:29,代码来源:class.plx.motor.php

示例7: validerCommande

 public function validerCommande()
 {
     $tabChoixMethodespaiement = $this->donneesModeles["tabChoixMethodespaiement"];
     if (isset($_POST["methodpayment"]) && !isset($tabChoixMethodespaiement[$_POST["methodpayment"]])) {
         // si la méthode de paiement n'est pas autorisé, choix par défaut
         $_POST["methodpayment"] = current($tabChoixMethodespaiement);
     }
     $msgCommand = "";
     $TONMAIL = $this->getParam('email');
     $TON2EMEMAIL = $this->getParam('email_cc');
     $SHOPNAME = $this->getParam('shop_name');
     $COMMERCANTNAME = $this->getParam('commercant_name');
     $COMMERCANTPOSTCODE = $this->getParam('commercant_postcode');
     $COMMERCANTCITY = $this->getParam('commercant_city');
     $COMMERCANTSTREET = $this->getParam('commercant_street');
     //récupération de la liste des produit du panier
     $totalpricettc = 0.0;
     $totalpoidg = 0.0;
     $totalpoidgshipping = 0.0;
     $productscart = array();
     if (isset($_SESSION['prods'])) {
         foreach ($_SESSION['prods'] as $k => $v) {
             if (!isset($productscart[$v])) {
                 $productscart[$v] = array('name' => $this->aProds[$v]['name'], 'pricettc' => 0, 'poidg' => 0, 'nombre' => 0);
             }
             $totalpricettc = (double) $this->aProds[$v]['pricettc'] + (double) $totalpricettc;
             $totalpoidg = (double) $this->aProds[$v]['poidg'] + (double) $totalpoidg;
             $productscart[$v]["nombre"]++;
             $productscart[$v]["pricettc"] += $this->aProds[$v]['pricettc'];
             $productscart[$v]["poidg"] += $this->aProds[$v]['poidg'];
         }
         $totalpoidgshipping = $this->shippingMethod($totalpoidg, 1);
     }
     #Mail de nouvelle commande pour le commerçant.
     $sujet = $this->getlang('L_EMAIL_SUBJECT') . $SHOPNAME;
     $message = plxUtils::cdataCheck($_POST['firstname']) . " " . plxUtils::cdataCheck($_POST['lastname']) . "<br/>" . plxUtils::cdataCheck($_POST['adress']) . "<br/>" . plxUtils::cdataCheck($_POST['postcode']) . " " . plxUtils::cdataCheck($_POST['city']) . "<br/>" . plxUtils::cdataCheck($_POST['country']) . "<br/>" . $this->getlang('L_EMAIL_TEL') . plxUtils::cdataCheck($_POST['tel']) . "<br/><br/>" . (!isset($_POST["choixCadeau"]) ? $this->getlang('L_EMAIL_NOGIFT') : $this->getlang('L_EMAIL_GIFT_FOR') . " <strong>" . htmlspecialchars($_POST["nomCadeau"]) . "</strong>.") . "<br/><br/>" . $this->getlang('L_PAIEMENT') . ": " . ($_POST['methodpayment'] == "paypal" ? $this->getlang('L_PAYMENT_PAYPAL') : $this->getlang('L_PAYMENT_CHEQUE')) . "<br>" . $this->getlang('L_EMAIL_PRODUCTLIST') . " :<br/><ul>";
     foreach ($productscart as $k => $v) {
         $message .= "<li>{$v['nombre']} × " . $v['name'] . "&nbsp;: " . $this->pos_devise($v['pricettc']) . ((double) $v['poidg'] > 0 ? " " . $this->getlang('L_FOR') . " " . $v['poidg'] . "Kg" : "") . "</li>";
     }
     $message .= "</ul><br/><br>" . "<strong>" . $this->getlang('L_EMAIL_TOTAL') . ": " . $this->pos_devise($totalpricettc + $totalpoidgshipping) . "</strong><br/><em><strong>" . $this->getlang('L_EMAIL_DELIVERY_COST') . " : " . $this->pos_devise($totalpoidgshipping) . "</strong><br/>" . "<strong>" . $this->getlang('L_EMAIL_WEIGHT') . " : " . $totalpoidg . "&nbsp;kg</strong><br/><br/></em>" . $this->getlang('L_EMAIL_COMMENT') . " : <br>" . plxUtils::cdataCheck($_POST['msg']);
     $destinataire = $TONMAIL . (isset($TON2EMEMAIL) && !empty($TON2EMEMAIL) ? ', ' . $TON2EMEMAIL : "");
     $headers = "MIME-Version: 1.0\r\nFrom: \"" . plxUtils::cdataCheck($_POST['firstname']) . " " . plxUtils::cdataCheck($_POST['lastname']) . "\"<" . $_POST['email'] . ">\r\n";
     $headers .= "Reply-To: " . $_POST['email'] . "\r\nX-Mailer: PHP/" . phpversion() . "\r\nX-originating-IP: " . $_SERVER["REMOTE_ADDR"] . "\r\n";
     $headers .= "Content-Type: text/html;charset=UTF-8\r\nContent-Transfer-Encoding: 8bit\r\nX-Priority: 1\r\nX-MSMail-Priority: High\r\n";
     if (isset($_POST['email']) && $_POST['email'] != "" && (isset($_POST['firstname']) && plxUtils::cdataCheck($_POST['firstname']) != "") && (isset($_POST['lastname']) && plxUtils::cdataCheck($_POST['lastname']) != "") && (isset($_POST['adress']) && plxUtils::cdataCheck($_POST['adress']) != "") && (isset($_POST['postcode']) && plxUtils::cdataCheck($_POST['postcode']) != "") && (isset($_POST['city']) && plxUtils::cdataCheck($_POST['city']) != "") && (isset($_POST['country']) && plxUtils::cdataCheck($_POST['country']) != "") && (!isset($_POST['choixCadeau']) || plxUtils::cdataCheck($_POST['nomCadeau']) != "")) {
         if (mail($destinataire, $sujet, $message, $headers)) {
             if ($_POST['methodpayment'] == "paypal") {
                 $msgCommand .= "<h2 class='h2okmsg' >" . $this->getlang('L_EMAIL_CONFIRM_PAYPAL') . "</h2>";
             } else {
                 if ($_POST['methodpayment'] == "cheque") {
                     $msgCommand .= "<h2 class='h2okmsg'>" . $this->getlang('L_EMAIL_CONFIRM_CHEQUE') . "</h2>";
                 } else {
                     if ($_POST['methodpayment'] == "cash") {
                         $msgCommand .= "<h2 class='h2okmsg'>" . $this->getlang('L_EMAIL_CONFIRM_CASH') . "</h2>";
                     }
                 }
             }
             #Mail de récapitulatif de commande pour le client.
             switch ($_POST['methodpayment']) {
                 case 'cheque':
                     $status = $this->getlang('L_WAITING');
                     $method = $this->getlang('L_PAYMENT_CHEQUE');
                     break;
                 case 'cash':
                     $status = $this->getlang('L_WAITING');
                     $method = $this->getlang('L_PAYMENT_CASH');
                     break;
                 case 'paypal':
                     $status = $this->getlang('L_ONGOING');
                     $method = $this->getlang('L_PAYMENT_PAYPAL');
                     break;
                 default:
                     echo 'A method of payment is required!';
             }
             $sujet = $this->getlang('L_EMAIL_CUST_SUBJECT') . $SHOPNAME;
             $message = "<p>" . $this->getlang('L_EMAIL_CUST_MESSAGE1') . " <a href='http://" . $_SERVER["HTTP_HOST"] . "'>" . $SHOPNAME . "</a><br>" . $this->getlang('L_EMAIL_CUST_MESSAGE2') . " " . $status . " " . $this->getlang('L_EMAIL_CUST_MESSAGE3') . "</p>";
             if ($_POST['methodpayment'] == "cheque") {
                 $message .= "<p>" . $this->getlang('L_EMAIL_CUST_CHEQUE') . " : " . $COMMERCANTNAME . "<br>" . $this->getlang('L_EMAIL_CUST_SENDCHEQUE') . " :" . "<br><em>&nbsp;&nbsp;&nbsp;&nbsp;" . $SHOPNAME . "" . "<br>&nbsp;&nbsp;&nbsp;&nbsp;" . $COMMERCANTNAME . "" . "<br>&nbsp;&nbsp;&nbsp;&nbsp;" . $COMMERCANTSTREET . "" . "<br>&nbsp;&nbsp;&nbsp;&nbsp;" . $COMMERCANTPOSTCODE . " " . $COMMERCANTCITY . "</em></p>";
             } elseif ($_POST['methodpayment'] == "cash") {
                 $message .= "<p>" . $this->getlang('L_EMAIL_CUST_CASH') . "</p>";
             } elseif ($_POST['methodpayment'] == "paypal") {
                 $message .= "<p>" . $this->getlang('L_EMAIL_CUST_PAYPAL') . "</p>";
             }
             $message .= "<br><h1><u>" . $this->getlang('L_EMAIL_CUST_SUMMARY') . " :</u></h1>" . "<br><strong>" . $this->getlang('L_EMAIL_CUST_ADDRESS') . " :</strong><br/>" . plxUtils::cdataCheck($_POST['firstname']) . " " . plxUtils::cdataCheck($_POST['lastname']) . "<br/>" . plxUtils::cdataCheck($_POST['adress']) . "<br/>" . plxUtils::cdataCheck($_POST['postcode']) . " " . plxUtils::cdataCheck($_POST['city']) . "<br/>" . plxUtils::cdataCheck($_POST['country']) . "<br/>" . "<strong>Tel : </strong>" . plxUtils::cdataCheck($_POST['tel']) . "<br/><br/>" . (!isset($_POST["choixCadeau"]) ? $this->getlang('L_EMAIL_NOGIFT') : $this->getlang('L_EMAIL_GIFT_FOR') . " <strong>" . htmlspecialchars($_POST["nomCadeau"]) . "</strong>.") . "<br/><br/>" . "<strong>" . $this->getlang('L_EMAIL_CUST_PAYMENT') . ": </strong>" . $method . "<br><strong>" . $this->getlang('L_EMAIL_PRODUCTLIST') . " :</strong><br/>";
             foreach ($productscart as $k => $v) {
                 $message .= "<li>{$v['nombre']} × " . $v['name'] . "&nbsp;: " . $this->pos_devise($v['pricettc']) . ((double) $v['poidg'] > 0 ? " " . $this->getlang('L_FOR') . " " . $v['poidg'] . "&nbsp;kg" : "") . "</li>";
             }
             $message .= "<br/><br>" . "<strong>" . $this->getlang('L_EMAIL_TOTAL') . " : </strong>" . $this->pos_devise($totalpricettc + $totalpoidgshipping) . "<br/>" . "<em><strong>" . $this->getlang('L_EMAIL_DELIVERY_COST') . " : </strong>" . $this->pos_devise($totalpoidgshipping) . "<br/>" . "<strong>" . $this->getlang('L_EMAIL_WEIGHT') . " : </strong>" . $totalpoidg . "&nbsp;kg<br/><br/></em>" . "<strong>" . $this->getlang('L_EMAIL_COMMENT') . " : </strong><br>" . plxUtils::cdataCheck($_POST['msg']);
             $destinataire = $_POST['email'];
             $headers = "MIME-Version: 1.0\r\nFrom: \"" . $SHOPNAME . "\"<" . $TONMAIL . ">\r\n";
             $headers .= "Reply-To: " . $TONMAIL . (isset($TON2EMEMAIL) && !empty($TON2EMEMAIL) ? ', ' . $TON2EMEMAIL : "") . "\r\nX-Mailer: PHP/" . phpversion() . "\r\nX-originating-IP: " . $_SERVER["REMOTE_ADDR"] . "\r\n";
             $headers .= "Content-Type: text/html;charset=UTF-8\r\nContent-Transfer-Encoding: 8bit\r\nX-Priority: 1\r\nX-MSMail-Priority: High\r\n";
             if (mail($destinataire, $sujet, $message, $headers)) {
                 $msgCommand .= "<h2 class='h2okmsg2'>" . $this->getlang('L_EMAIL_SENT1') . "</h2>";
                 $msgCommand .= "<h2 class='h2okmsg3'>" . sprintf($this->getlang('L_EMAIL_SENT2'), $TONMAIL) . "</h2>";
                 if ($_POST['methodpayment'] === "paypal") {
                     $plxPlugin = $this;
                     //require PLX_PLUGINS . 'plxMyShop/paypal_api/SetExpressCheckout.php';
                     require PLX_PLUGINS . 'plxMyShop/paypal_api/boutonPaypalSimple.php';
                 }
//.........这里部分代码省略.........
开发者ID:ppmt,项目名称:plxMyShop,代码行数:101,代码来源:plxMyShop.php

示例8:

?>
';
var L_DEL = '<?php 
echo $plxPlugin->getlang('L_DEL');
?>
';
var L_TOTAL = '<?php 
echo $plxPlugin->getlang('L_TOTAL_BASKET');
?>
';



</script>

<?php 
// e-mail de la commande
$_SESSION['msgCommand'] = "";
if (isset($_POST['prods']) && plxUtils::cdataCheck($_POST['prods']) != "") {
    $plxPlugin->validerCommande();
}
if ("1" === $plxPlugin->aProds[$plxPlugin->productNumber()]['pcat']) {
    $plxPlugin->modele("espacePublic/categorie");
} else {
    $plxPlugin->modele("espacePublic/produit");
}
if (in_array($plxPlugin->getParam("affPanier"), array("basPage", "partout"))) {
    $plxPlugin->modele("espacePublic/panier");
} else {
    $plxPlugin->modele("espacePublic/ajoutProduit");
}
开发者ID:ppmt,项目名称:plxMyShop,代码行数:31,代码来源:form.product.php


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