Choix utilisateur pour la maîtrise de la langue est : Ecrit Ton information a été ajouté correctement !!!. Choix utilisateur pour la maîtrise de la langue est : Oral Ton information a été ajouté correctement !!!.
Choix utilisateur pour la maîtrise de la langue est : Ecrit
$execute = mysql_query($sql) or die(mysql_error());
Vous n’avez pas trouvé la réponse que vous recherchez ?
Posez votre question"; $sql= "INSERT into parle (code_langue,degre_mait_lang,mode_mait_lang) VALUES ('$code_langue','$degre_mait_lang','$choix')"; // on insère les informations du formulaire dans la table mysql_query($sql) or die('Erreur SQL !'.$sql.' '.mysql_error()); print(' Ton information a été ajouté correctement !!!. '); } } // déconnexion à la base mysql_close(); ?>
<? session_start(); ?> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <title>Document sans titre</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> </head> <? if ($_POST['code_langue'] == "Allemand") { $code_langue= 1; } else if ($_POST['code_langue']== "Anglais") {$code_langue= 2; } else if ($_POST['code_langue'] == "Arabe") { $code_langue= 3; } else if ($_POST['code_langue']=="Bulgare") { $code_langue=4; } else if ($_POST['code_langue']=="Chinois") { $code_langue=5; } else if ($_POST['code_langue'] == "Croate") { $code_langue= 6; } else if ($_POST['code_langue']== "Danois") {$code_langue= 7; } else if ($_POST['code_langue']=="Espagnol") { $code_langue=8; } else if ($_POST['code_langue']=="Finois") { $code_langue=9; } else if ($_POST['code_langue']=="Français") { $code_langue=10;} else if ($_POST['code_langue']=="Grec") { $code_langue=12; } else if ($_POST['code_langue']=="Hongrois") { $code_langue=13; } else if ($_POST['code_langue']=="Indien") { $code_langue=14; } else if ($_POST['code_langue']=="Islandais") { $code_langue=15; } else if ($_POST['code_langue']=="Italien") { $code_langue=16; } // CONNEXION A LA BASE DE DONNEES include ("connexion_eurocall.php"); $id = MYSQL_CONNECT($host,$user,$pass); mysql_select_db("$bdd"); echo "Connexion établit avec la BD"; //FIN DE CONNEXION $code_langue=$_POST['code_langue']; $degre_mait_lang=$_POST['degre_mait_lang']; $mode_mait_lang=$_POST['mode_mait_lang']; $Submit=$_POST['Submit']; /*if($autre!="") { $intitule_dom=$autre; }*/ if(isset($Submit)) { if (isset($_POST['code_langue'])) // if (isset($_POST['degre_mait_lang'])) if (is_array($_POST['mode_mait_lang'])) { foreach($_POST['mode_mait_lang'] as $choix) { echo ("Choix utilisateur pour la maîtrise de la langue est : ",$choix," "); $sql= ("INSERT into parle (code_langue,degre_mait_lang,mode_mait_lang) VALUES ('$code_langue','$degre_mait_lang','$choix')"); // on insère les informations du formulaire dans la table mysql_query($sql) or die('Erreur SQL !'.$sql.' '.mysql_error()); print('Ton information a été ajouté correctement !!!. '); } } // déconnexion à la base mysql_close(); ?> </html>