pdo = Connection::getPDO(); $user = new User(); $error = []; $errors = null; if(!empty($_POST['username'])){ $user->setUsername($_POST['username']); $u = (new UserTable($pdo))->login($user ,$_POST['password']); if($u !== null){ session_start
PDO("sqlite:..//bdd/gestion.sql"); $bdd->exec("CREATE TABLE addtable ( id INTEGER PRIMARY KEY AUTOINCREMENT, dpt varchar(250) NOT NULL, cours varchar(250) NOT NULL, matiere varchar(250) NOT NULL, salle varchar
PDO) // ici ça pose probleme avec des namespaces * etc.* * **/vendor** (composer) * composer.json * index.php et voici mon index.php racine : ``` // Load the config file require_once 'config.inc'; /* * __autoload($class) * @desc Please refer
PDO::PARAM_STR); $req->bindValue(':token', $token, PDO::PARAM_STR); $req->execute(); $link = 'Bonjour, veuillez cliquer sur ce lien pour réinitialiser votre mote de passe.'; // Create the Transport $transport = (new Swift
PDO var_dump($_POST); var_dump($_FILES); if( isset($_POST) ) // si formulaire soumis { if( !is_uploaded_file($tmp_file) ) { $errorMessage = "Le fichier est introuvable"; header('Location: ../adminAddActualite.php'); } if( !strstr($type
pdo pdo_mysql opcache intl zip calendar dom mbstring gd xsl \ \ && pecl install apcu && docker-php-ext-enable apcu WORKDIR /var/www/ ``` Et mon vhosts.conf pour apache : ``` ServerName localhost
pdo = Connect::getPDO(); $photoTable = new PhotoTable($pdo); if(isset($_GET['url'])){ $url = $_GET['url']; $photo = $photoTable->find($photoTable->findField('path', $url)); $data = [ 'title' => $photo->getTitle(), 'text' => $photo->getText() ]; echo json
pdo->prepare('SELECT * FROM users WHERE (username = :username OR email = :username) AND (confirmed_at IS NOT NULL AND is_confirmed = 1)'); $req->execute(['username' => $_POST['pseudo']]); $user = $req->fetch(); if ($user
PDO $db = new PDO('mysql:host=localhost;dbname=test','root',''); } catch(Exception $e) { die('Erreur : '.$e->getMessage()); } //$reponse = $db->query('SELECT id,titre,contenu FROM billets'); ?> Modifier une new Modifier
PDO. Et j'ai un problème lors de l'insertion d'une nouvelles news ou d'un articles. La page articles.php