public function add($param = "") { global $myAdmin; global $formMaj; global $datas_lang; global $smarty; global $thisSite; $this->LANG_DATAS = $myAdmin->LANG_DATAS; parent::add(); $smarty->assign('this', $this); $smarty->assign('param', $param); $smarty->assign('language', $thisSite->LIST_LANG_COMP[$myAdmin->LANG_INTERFACE]); $toolbars = array(); $toolbars["Default"][1] = "cut copy paste pastetext | undo redo | bold italic underline strikethrough | subscript superscript | removeformat | charmap emoticons hr nonbreaking"; $toolbars["Default"][2] = "bullist numlist | outdent indent | alignleft aligncenter alignright alignjustify | image | inserttable tableprops deletetable cell row column | link unlink | anchor | template | visualblocks | code"; $toolbars["Default"][3] = "styleselect fontselect fontsizeselect | forecolor backcolor"; $toolbars["Basic"][1] = "bold italic underline strikethrough | subscript superscript | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent"; $toolbars["Basic"][2] = "styleselect | link unlink | image charmap | code"; $toolbars["Simple"][1] = "bold italic underline strikethrough | alignleft aligncenter alignright alignjustify | bullist numlist | link unlink | image charmap | code"; $toolbars["Image"][1] = "image | code"; $smarty->assign('toolbar', $toolbars[$this->toolbar]); $data = $smarty->fetch($this->pathTemplate . 'inc/fields/class.editortm.tpl'); addStructure("addJsStructure", DOS_OUTILS_ADMIN . "tinymceJQ/jquery.tinymce.min.js"); addStructure("addJsStructure", DOS_OUTILS_ADMIN . "tinymceJQ/tinymce.min.js"); $this->smartAssign($this->field, $data); return $data; }
public function add($param = "") { global $myAdmin; global $formMaj; global $datas_lang; global $smarty; global $thisSite; parent::add(); $smarty->assign('this', $this); $smarty->assign('param', $param); $data = $smarty->fetch($this->pathTemplate . 'inc/fields/class.editorck.tpl'); addStructure("addJsStructure", DOS_OUTILS_ADMIN . "ckeditor/ckeditor.js"); addStructure("addJsStructure", DOS_OUTILS_ADMIN . "ckeditor/adapters/jquery.js"); $this->smartAssign($this->field, $data); return $data; }
if ($idParent == "") { $idParent = $myAdmin->getDatasPage("idParent"); } ////////////////// if ($idParent > "0") { $myTableParent = $myAdmin->getDatasPage("myTable", $myAdmin->getChronoPages(1)); $infosParent = getInfosPageParent($myTableParent, $myAdmin->LANG_DATAS, $idParent, "titre"); } else { if ($__POST["id_parent"] != "") { $idParent = $__POST["id_parent"]; $myTableParent = $__POST["myTableParent"]; $infosParent = getInfosPageParent($myTableParent, $myAdmin->LANG_DATAS, $idParent, "titre"); } } addStructure("addCssStructure", DOS_SKIN_ADMIN . "style_list.css"); addStructure("addJsStructure", $thisSite->RACINE . $thisSite->DOS_ADMIN . DOS_OUTILS_ADMIN . "sortable/jquery-sortable-min.js"); $actionsPage = array("ajouter", "appliquer", "supprimer", "move"); if (strpos($myAdmin->niveaux2add, $myAdmin->newNiveau2 . ",") === false) { RemoveActionPage("ajouter"); } if (strpos($myAdmin->niveaux2del, $myAdmin->newNiveau2 . ",") === false) { RemoveActionPage("supprimer"); } if (strpos($myAdmin->niveaux2mod, $myAdmin->newNiveau2 . ",") === false) { RemoveActionPage("appliquer"); RemoveActionPage("valider"); } $filtres = $myAdmin->getDatasPage("Filtres", $myAdmin->getChronoPages(1)); // récup filtres page List include DOS_BASE_ADMIN . "inc/" . "selectVariables.php"; if ($__POST["actionInList"] == "move") {
public function add($param = "") { if (!is_array($this->items) && $this->tags != true) { return 0; } global $myAdmin; global $formMaj; global $datas_lang; global $smarty; global $thisSite; if ($this->tags == true) { $this->multiLang = false; // multilangue géré par la table des tags } $this->LIST_LANG_EXTENSION_FIELD = $myAdmin->LIST_LANG_EXTENSION_FIELD; parent::add(); $smarty->assign('this', $this); $listDisabled = array(); if (!is_array($this->valuesDisabled)) { $valuesDisabled = explode(",", $this->valuesDisabled); $listDisabled = $valuesDisabled; } else { $listDisabled = $this->valuesDisabled; } foreach ($this->list_lang as $clg => $extlg) { $value = $this->getValue($clg); $values = explode(",", $value); if (!is_array($values)) { $values = array(); } if ($this->tags == true) { if ($listItems == "") { $listItems = array(); $mySelect2 = new mySelect(__FILE__); $mySelect2->tables = $thisSite->PREFIXE_TBL_GEN . "tags"; $mySelect2->fields = "*"; $mySelect2->where = "parent=:parent AND lg=:lg"; $mySelect2->whereValue["parent"] = array($this->field, PDO::PARAM_STR); $mySelect2->whereValue["lg"] = array("fr", PDO::PARAM_STR); $mySelect2->orderby = "titre ASC"; $result2 = $mySelect2->query(); foreach ($result2 as $row2) { $listItems[$row2['id']] = $row2['titre']; } } } else { $listItems = $this->items; } if ($this->iconeLangue() == true || $this->tags == true) { $smarty->assign('marginLeft', 50); } else { $smarty->assign('marginLeft', 0); } $indice = 0; $datasItem = array(); $count_items = count($listItems); $myGroup = ""; foreach ($listItems as $val => $text) { $val = delQuotes($val); $value = delQuotes($value); if (in_array($val, $listDisabled)) { $stateDisabled = "state-disabled"; $disabled = "disabled"; } else { $stateDisabled = ""; $disabled = ""; } if (in_array(htmlspecialchars($val, ENT_QUOTES), $values)) { $selected = "selected"; } else { $selected = ""; } if ($count_items == 1) { $str_indice = ""; } else { $str_indice = "_" . $indice; } $idField = $this->field . $extlg . $str_indice; $datasItem[$indice] = array("val" => $val, "text" => $text, "idField" => $idField, "stateDisabled" => $stateDisabled, "disabled" => $disabled, "selected" => $selected); $myGroup = $idField; $indice++; $marginLeft = 0; } //echoa($datasItem); $datasItemByLg[$clg] = $datasItem; } // lg $smarty->assign('datasItemByLg', $datasItemByLg); $allmyGroup = $smarty->getTemplateVars("myGroup"); $allmyGroup .= $this->field . $extlg . ":\"" . $myGroup . "\",\n"; $smarty->assign("myGroup", $allmyGroup); $data = $smarty->fetch($this->pathTemplate . 'inc/fields/class.selectM.tpl'); addStructure("addJsStructure", DOS_OUTILS_ADMIN . "multiple-select/jquery.multiple.select.js"); $this->smartAssign($this->field, $data); return $data; }
<?php $pathIframe = "../../"; include $pathIframe . "init_pages/" . "iframe.php"; require_once $pathIframe . DOS_OUTILS_ADMIN . 'filelistclass/file_list.class.php'; addStructure("addCssStructure", DOS_SKIN_ADMIN . "file_list.class.css"); /* Suppression fichiers par case à cocher Changer Droits Move fichier Button: fichier déjà utilisé dans la table // UPLOAD Upload autorisé ou non Extensions autorisées Redim dans X tailles (taille large, vig1, vig2, etc.) (array) Poids Max Interdire (renomer) les fichiers avec des caractères invalides Gérer et Afficher infos sur redimenssionnement, etc.. comme actuellement */ $racine_root = "../../../"; $racine_start = $racine_root . $thisSite->DOS_CLIENT_FILES; $smarty->assign("width_thumbs", 100); // infos du champ d'appel if (isset($__GET['field'])) { $field = $__GET['field']; } if ($field == "") { die; }
<?php include DOS_INC_ADMIN . "controle_login.php"; $typePage = "list"; if (@$come_by_index != 1) { echo "passer par devant. merci."; exit; } // sécurité si appel du script PHP sans passer par l'index $myAdmin->setChronoPages(); $myAdmin->setDatasPage("myTable", $myTable); addStructure("addCssStructure", DOS_SKIN_ADMIN . "style_list.css"); if ($myAdmin->PRIVILEGE < 9 && is_array($actionsPageOnlySA)) { foreach ($actionsPageOnlySA as $action) { RemoveActionPage($action); } } if (strpos($myAdmin->niveaux2add, $myAdmin->newNiveau2 . ",") === false) { RemoveActionPage("ajouter"); RemoveActionPage("dupliquer"); } if (strpos($myAdmin->niveaux2del, $myAdmin->newNiveau2 . ",") === false) { RemoveActionPage("supprimer"); } if ($myAdmin->paramlienPage != "") { $paramsPage = explode(",", $myAdmin->paramlienPage); foreach ($paramsPage as $paramPage) { list($codpar, $valpar) = explode("=", $paramPage); ${$codpar} = $valpar; } }
public function load() { global $smarty; global $datas_lang; global $__GET; global $__POST; global $thisSite; $params_outil = $this->params; // Permet d'utiliser $params_outil dans les outils comme infos spécifiques complémentaires $chemin_outil = get_path_outils($this->outilPathName) . "/"; // chargement des données langues du menu load_data_lang_plus($this->outil, $chemin_outil); $smarty->assign("datas_lang", $datas_lang); // Execution du outil $SHOW_outil = 1; // permet d'arréter le traitement du outil après le script PHP (pas de templates, ni d'autres éléments: JS: CSS, Javascript, ... if (file_exists($chemin_outil . $this->ssOutil . ".php")) { include $chemin_outil . $this->ssOutil . ".php"; } if ($SHOW_outil == 1) { // chargement de la feuille de sytle suivant la SKIN en cours, sinon on prend defaut $style_courant = str_replace($thisSite->DOS_CLIENT_SKIN, "", $thisSite->skin); $style_courant = str_replace("/", "", $style_courant); // Chargement d'une CSS de base $listCss = array(); $listCss[] = "defaut.css"; // on essaye d'abord de charger celle ci $listCss[] = $style_courant . ".css"; // sinon celle portant le nom de la Skin en cours $listCss[] = $this->outil . ".css"; // sinon la CSS portant le même nom que l'outil $listCss = array_unique($listCss); foreach ($listCss as $css) { if ($css != "") { $pathCss = $chemin_outil . $css; if (file_exists($pathCss)) { addStructure("PAGE_css_client", $pathCss); break; } } } // Chargement de CSS supplémentaires $listCss = array(); if (!is_array($this->css)) { $listCss = array($this->css); } else { $listCss = $this->css; } if (is_array($listCss)) { foreach ($listCss as $css) { if ($css != "") { $pathCss = $chemin_outil . $css; if (file_exists($pathCss)) { addStructure("PAGE_css_client", $pathCss); } } } } // JS // par défaut, on charge le JS portant le meme nom que le module if (file_exists($chemin_outil . $this->outil . ".js")) { addStructure("PAGE_js_client", $chemin_outil . $this->outil . ".js"); } // on regarde si il y a d'autres JS à charger if (!is_array($this->js) && $this->js != "") { $this->js = array($this->js); } if (is_array($this->js)) { foreach ($this->js as $k => $js) { if (strpos($js, 'http') === 0) { addStructure("PAGE_js_client", $js); } else { if (file_exists($chemin_outil . $js) && $js != "") { addStructure("PAGE_js_client", $chemin_outil . $js); } } } } if ($this->head != "") { addStructure("PAGE_head", $this->head . "\n\n"); } if ($this->doc_ready != "") { addStructure("PAGE_doc_ready", $this->doc_ready . "\n\n"); } if ($this->win_load != "") { addStructure("PAGE_win_load", $this->win_load . "\n\n"); } if ($this->javascript != "") { addStructure("PAGE_javascript", $this->javascript . "\n\n"); } if ($this->footer != "") { addStructure("PAGE_footer", $this->footer . "\n\n"); } if ($outil_template == "") { $outil_template = $this->ssOutil; } if (file_exists($chemin_outil . $outil_template . ".tpl")) { $tpl_outil = $smarty->fetch($chemin_outil . $outil_template . ".tpl"); $smarty->assign("outil_" . $outil_template, $tpl_outil); } } //$SHOW_outil // IMPORTANT pour les outils suivants à traiter $outil_template = ""; }
<?php $myTable = $thisSite->PREFIXE_TBL_GEN . "arbo"; $myTableMenus = $thisSite->PREFIXE_TBL_GEN . "menus"; $myTablePages = $thisSite->PREFIXE_TBL_GEN . "pages"; $actionsPage = array("appliquer"); addStructure("addCssStructure", DOS_SKIN_ADMIN . "nestedSortable.css"); addStructure("addJsStructure", $thisSite->RACINE . $thisSite->DOS_ADMIN . DOS_OUTILS_ADMIN . "nestedSortable/jquery-ui-1.10.4.custom.min.js"); addStructure("addJsStructure", $thisSite->RACINE . $thisSite->DOS_ADMIN . DOS_OUTILS_ADMIN . "nestedSortable/jquery.mjs.nestedSortable.js"); include DOS_INCPAGES_ADMIN . "defaut-init.php"; //echoa($__POST); // Ajout d'une page dans l'arbo if ($__POST["newPage"] != "") { $classPage = new classPage(); $classPage->idPage = $__POST["newPage"]; $classPage->code_menu = $__POST["menu"]; $classPage->addArbo(); } if ($__POST["newArbo"] != "") { $posts = json_decode(stripslashes($__POST["newArbo"])); //echoa($posts ); if (is_array($posts)) { foreach ($posts as $nivMenu) { $menu = $nivMenu->id; $Rubs = array(); $sRubs = array(); $arbo_menu = array(); if (is_array($nivMenu->children)) { foreach ($nivMenu->children as $nivRub) { $arbo_menu[$nivRub->id] = ""; $sRubs = array();
<?php $style = "dark"; // light ou dark if ($thisSite->current_lang == "fr") { $policyText = "En savoir plus"; $text = "En poursuivant votre navigation sur ce site, vous acceptez l´utilisation des cookies qui nous permettent de vous proposer des services et une offre adaptés à vos centres d´intérêts."; $btnText = "OK"; $link = $thisSite->DOS_CLIENT . "_modules/_cookies_accept/cookies_fr.php"; } else { $policyText = "Privacy policy"; $text = "We use cookies to ensure you get the best experience on our website, if you continue to browse you´ll be acconsent with our"; $btnText = "OK"; $link = $thisSite->DOS_CLIENT . "_modules/_cookies_accept/cookies_en.php"; } addStructure("PAGE_doc_ready", "\$(document).herbyCookie({\n style: '" . $style . "',\n policyText: '" . $policyText . "',\n text: '" . $text . "',\n btnText: '" . $btnText . "', \n link: '" . $link . "',\n remove: false\n });" . "\n\n");
<?php addStructure("PAGE_head", "<link href='https://www.google.com/fonts#UsePlace:use/Collection:Open+Sans:400,700,400italic,700italic' rel='stylesheet' type='text/css'>"); /////////////////////// INITIALISATION des MODULES de BASE ////////////////////////////////////////////// if ($thisSite->SERVER != "local") { $obj_module = new module("_boutons_partage"); $obj_module->doc_ready = "\$(\".shareIcons\").jsSocials({showLabel: false, showCount: false , shares: [\"facebook\", \"twitter\", \"googleplus\", \"linkedin\"]});"; $obj_module->load(); } $obj_module = new module("_favicon"); $obj_module->load(); $obj_module = new module("_header"); $obj_module->load(); $obj_module = new module("_footer"); $obj_module->load(); /////////////////////// INITIALISATION CSS + JS ////////////////////////////////////////////// $obj_outil = new outil("lib"); $obj_outil->css = array("css/bootstrap.min.css", "css/metisMenu.css", "css/morris.css", "css/sb-admin-2.css"); $obj_outil->js = array("js/bootstrap.min.js", "js/jquery.flexisel.js", "js/metisMenu.js", "js/morris.js"); $obj_outil->load();