On 17 January 2017 at 15:25, Arthur Carvalho <arthur.carvalho2...@gmail.com>
wrote:

> Hello,
>
> I have a problem with my php code.
>
> I hope you will answer !
>

Hello.

This is the mailing list for people having issues/comments/feedback on the
PHP website itself, not a support channel.

Please take a look here for another channel for support:
http://php.net/support.php


>
> I'm working for my Baccalauréat exam and this code is very important.
>
> I'm trying to creating an SQL table and the name of this table is a text
> imported from another page with the POST method, and the problem seems to
> be in the local variable I'm trying to include in the sql query:
>
> <?php
>
> $a = $_POST['auteur'];
> try
>
> {
>        $bdd = new PDO('mysql:host=***;dbname=***','***','***');
> }
>
> catch(Exception $e)
>
> {
>        die('Erreur : '.$e->getMessage());
> }
>
> $query = "CREATE TABLE IF NOT EXISTS `$a` (
> `id` INT NOT NULL AUTO_INCREMENT PRIMARY KEY)";
>
> header("Location: Gestion Catalogue.php/");
> ?>
>
> Please I do need your help !
> --
> Arthur CARVALHO
> +33 6 30 81 11 78
> arthur.carvalho2...@gmail.com
>



-- 

Mike Griffiths
mgriffi...@gmail.com

Reply via email to