Mysql des champ mais vide....................
Alexandre
-
Alexandre -
Alexandre -
Bonjour tout le monde.
Je suis entrain de faire mon site web et je suis entrain de faire un petit test sur mysql et php et sa s`averent que j`ai des problème lol. Voici mon code... Par la suite je vous explique mon problème...
<index.html>:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Document sans nom</title>
</head>
<body>
Le nom a entrer
<form method="post" action="test.php">
<input type="text" name="nom" value="" maxlength="100" size="55">
<input type="image" src="http://www.thesportshq.com/images/en/add.gif" Border=0 name="submit">
</body>
</html>
Ensuite dans le test.html:
<?PHP
$db = mysql_connect('sql.XXXXXXXXXXX.com', 'XXXX', 'XXXX');
mysql_select_db('XXXXXXXXXX',$db);
$sql = "INSERT INTO amis
VALUES('$nom')";
mysql_query($sql)
or die('Erreur SQL !'.$sql.'
'.mysql_error());
echo 'merci beaucoup, vos infos ont été enregistrées.';
mysql_close();
?>
Mon problème:
-Apres avoir entrer un nom sa marque "merci beaucoup vos infos ont été enregistrer mais c`est pas vrai!!
Dans phpAdmin il m`affiche bien un champ de + a chaque fois que je clique ajouter mais c`est un champ vide....
Voici la config de ma base de donner mysql:
-(http://img64.imageshack.us/img64/1994/12ki0.jpg)
Merci de m`aidez... Et bonne nuit lol chez moi il est tard...
Je suis entrain de faire mon site web et je suis entrain de faire un petit test sur mysql et php et sa s`averent que j`ai des problème lol. Voici mon code... Par la suite je vous explique mon problème...
<index.html>:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Document sans nom</title>
</head>
<body>
Le nom a entrer
<form method="post" action="test.php">
<input type="text" name="nom" value="" maxlength="100" size="55">
<input type="image" src="http://www.thesportshq.com/images/en/add.gif" Border=0 name="submit">
</body>
</html>
Ensuite dans le test.html:
<?PHP
$db = mysql_connect('sql.XXXXXXXXXXX.com', 'XXXX', 'XXXX');
mysql_select_db('XXXXXXXXXX',$db);
$sql = "INSERT INTO amis
VALUES('$nom')";
mysql_query($sql)
or die('Erreur SQL !'.$sql.'
'.mysql_error());
echo 'merci beaucoup, vos infos ont été enregistrées.';
mysql_close();
?>
Mon problème:
-Apres avoir entrer un nom sa marque "merci beaucoup vos infos ont été enregistrer mais c`est pas vrai!!
Dans phpAdmin il m`affiche bien un champ de + a chaque fois que je clique ajouter mais c`est un champ vide....
Voici la config de ma base de donner mysql:
-(http://img64.imageshack.us/img64/1994/12ki0.jpg)
Merci de m`aidez... Et bonne nuit lol chez moi il est tard...
A voir également:
- Mysql des champ mais vide....................
- Supprimer page word vide - Guide
- Caractere vide - Guide
- Coeur vide ✓ - Forum Réseaux sociaux
- Le nom du champ de tableau croisé dynamique n'est pas valide ✓ - Forum Excel
- Code pour écrire un coeur VIDE : alt+??? ✓ - Forum Mail
1 réponse
Excuser je me suis tromper dans l`adresse de ma configuration: [url=https://imageshack.com/][img=http://img162.imageshack.us/img162/8236/12kl3.th.jpg][/url]
<a href="https://imageshack.com/" target="_blank"><img src="http://img162.imageshack.us/img162/8236/12kl3.th.jpg" border="0" alt="Free Image Hosting at www.ImageShack.us" /></a>
<a href="https://imageshack.com/" target="_blank"><img src="http://img162.imageshack.us/img162/8236/12kl3.th.jpg" border="0" alt="Free Image Hosting at www.ImageShack.us" /></a>