$xoopsOption['template_main'] = 'oledrion_index.tpl'; require_once XOOPS_ROOT_PATH . '/header.php'; require_once OLEDRION_PATH . 'class/registryfile.php'; // Initialisations $start = isset($_GET['start']) ? intval($_GET['start']) : 0; $limit = oledrion_utils::getModuleOption('newproducts'); // Nombre maximum d'éléments à afficher $baseurl = OLEDRION_URL . basename(__FILE__); // URL de ce script (sans son nom) $registry = new oledrion_registryfile(); $lastTitle = ''; // Quelques options pour le template $xoopsTpl->assign('nostock_msg', oledrion_utils::getModuleOption('nostock_msg')); $xoopsTpl->assign('mod_pref', $mod_pref); // Préférences du module $xoopsTpl->assign('welcome_msg', nl2br($registry->getfile(OLEDRION_TEXTFILE1))); $xoopsTpl->assign('columnsCount', oledrion_utils::getModuleOption('index_colums')); // Lecture des TVA ******************************************************************************** $vatArray = $h_oledrion_vat->getAllVats(new oledrion_parameters()); // Récupération du nombre total de produits de la base $xoopsTpl->assign('total_products_count', sprintf(_OLEDRION_THEREARE, $h_oledrion_products->getTotalPublishedProductsCount())); if ($limit > 0) { $itemsCount = $h_oledrion_products->getRecentProductsCount(); if ($itemsCount > $limit) { require_once XOOPS_ROOT_PATH . '/class/pagenav.php'; $pagenav = new XoopsPageNav($itemsCount, $limit, $start); $xoopsTpl->assign('pagenav', $pagenav->renderNav()); } $oledrion_shelf_parameters->resetDefaultValues()->setProductsType('recent')->setStart($start)->setLimit($limit)->setSort('product_id DESC, product_title')->setWithXoopsUser(true)->setWithRelatedProducts(true); $products = $oledrion_shelf->getProducts($oledrion_shelf_parameters); if (isset($products['lastTitle'])) {
* @author Hervé Thouzard (http://www.herve-thouzard.com/) * @version $Id: caddy.php 12290 2014-02-07 11:05:17Z beckmi $ */ /** * Affichage et gestion du caddy */ require 'header.php'; $GLOBALS['current_category'] = -1; $xoopsOption['template_main'] = 'oledrion_caddy.tpl'; require_once XOOPS_ROOT_PATH . '/header.php'; require_once OLEDRION_PATH . 'class/registryfile.php'; $xoopsTpl->assign('mod_pref', $mod_pref); // Préférences du module if (oledrion_utils::getModuleOption('restrict_orders', false)) { $registry = new oledrion_registryfile(); $text = $registry->getfile(OLEDRION_TEXTFILE5); $xoopsTpl->assign('restrict_orders_text', xoops_trim($text)); } else { $xoopsTpl->assign('restrict_orders_text', ''); } $op = 'default'; if (isset($_POST['op'])) { $op = $_POST['op']; } elseif (isset($_GET['op'])) { $op = $_GET['op']; } $productId = 0; if (isset($_POST['product_id'])) { $productId = intval($_POST['product_id']); } elseif (isset($_GET['product_id'])) { $productId = intval($_GET['product_id']);
* which is considered copyrighted (c) material of the original comment or credit authors. * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * * @copyright Hervé Thouzard of Instant Zero (http://www.instant-zero.com) * @license http://www.fsf.org/copyleft/gpl.html GNU public license * @package oledrion * @author Hervé Thouzard of Instant Zero (http://www.instant-zero.com) * * Version : $Id: * **************************************************************************** */ /** * Affichage des conditions générales de vente */ require 'header.php'; $GLOBALS['current_category'] = -1; $xoopsOption['template_main'] = 'oledrion_cgv.html'; require_once XOOPS_ROOT_PATH . '/header.php'; require_once OLEDRION_PATH . 'class/registryfile.php'; $registry = new oledrion_registryfile(); $xoopsTpl->assign('nostock_msg', oledrion_utils::getModuleOption('nostock_msg')); $xoopsTpl->assign('mod_pref', $mod_pref); // Préférences du module $xoopsTpl->assign('cgv_msg', $registry->getfile(OLEDRION_TEXTFILE2)); $xoopsTpl->assign('global_advert', oledrion_utils::getModuleOption('advertisement')); $xoopsTpl->assign('breadcrumb', oledrion_utils::breadcrumb(array(OLEDRION_URL . basename(__FILE__) => _OLEDRION_CGV))); oledrion_utils::setCSS(); oledrion_utils::setMetas(_OLEDRION_CGV . ' ' . oledrion_utils::getModuleName(), _OLEDRION_CGV . ' ' . oledrion_utils::getModuleName()); require_once XOOPS_ROOT_PATH . '/footer.php';
$msg['EMAIL'] = $commande->getVar('cmd_email'); $msg['URL_BILL'] = OLEDRION_URL . 'invoice.php?id=' . $commande->getVar('cmd_id') . '&pass='******'IP'] = oledrion_utils::IP(); if ($commande->getVar('cmd_bill') == 1) { $msg['FACTURE'] = _YES; } else { $msg['FACTURE'] = _NO; } // Envoi du mail au client oledrion_utils::sendEmailFromTpl('command_client.tpl', $commande->getVar('cmd_email'), sprintf(_OLEDRION_THANKYOU_CMD, $xoopsConfig['sitename']), $msg); // Envoi du mail au groupe de personne devant recevoir le mail oledrion_utils::sendEmailFromTpl('command_shop.tpl', oledrion_utils::getEmailsFromGroup(oledrion_utils::getModuleOption('grp_sold')), _OLEDRION_NEW_COMMAND, $msg); // Présentation du formulaire pour envoi à la passerelle de paiement // Présentation finale avec panier en variables cachées ****************************** $registry = new oledrion_registryfile(); $text = $registry->getfile(OLEDRION_TEXTFILE7); $xoopsTpl->assign('text', xoops_trim($text)); if (oledrion_utils::getModuleOption('offline_payment') == 1 && isset($_POST['offline_payment']) && intval($_POST['offline_payment']) == 0 || $commandAmountTTC == 0) { $payURL = XOOPS_URL; $text = $registry->getfile(OLEDRION_TEXTFILE4); $xoopsTpl->append('text', "<br />" . xoops_trim($text)); $sform = new XoopsThemeForm(_OLEDRION_FINISH, 'payform', $payURL, 'post'); $h_oledrion_caddy->emptyCart(); } else { if (is_object($gateway)) { $payURL = $gateway->getRedirectURL(); } else { $payURL = XOOPS_URL; } $sform = new XoopsThemeForm(_OLEDRION_PAY_GATEWAY, 'payform', $payURL, 'post'); $elements = array();
*/ if (!defined("OLEDRION_ADMIN")) { exit; } switch ($action) { // **************************************************************************************************************** case 'default': // Gestion des textes // **************************************************************************************************************** xoops_cp_header(); require_once OLEDRION_PATH . 'class/registryfile.php'; $registry = new oledrion_registryfile(); $sform = new XoopsThemeForm(_MI_OLEDRION_ADMENU8, 'frmatxt', $baseurl); $sform->addElement(new XoopsFormHidden('op', 'texts')); $sform->addElement(new XoopsFormHidden('action', 'savetexts')); $editor1 = oledrion_utils::getWysiwygForm(_AM_OLEDRION_INDEX_PAGE, 'welcome1', $registry->getfile(OLEDRION_TEXTFILE1), 5, 60, 'hometext1_hidden'); if ($editor1) { $sform->addElement($editor1, false); } $editor2 = oledrion_utils::getWysiwygForm(_OLEDRION_CGV, 'welcome2', $registry->getfile(OLEDRION_TEXTFILE2), 5, 60, 'hometext2_hidden'); if ($editor2) { $sform->addElement($editor2, false); } $editor3 = oledrion_utils::getWysiwygForm(_AM_OLEDRION_RECOMM_TEXT, 'welcome3', $registry->getfile(OLEDRION_TEXTFILE3), 5, 60, 'hometext3_hidden'); if ($editor3) { $sform->addElement($editor3, false); } $editor4 = oledrion_utils::getWysiwygForm(_AM_OLEDRION_OFFLINEPAY_TEXT, 'welcome4', $registry->getfile(OLEDRION_TEXTFILE4), 5, 60, 'hometext4_hidden'); if ($editor4) { $sform->addElement($editor4, false); }