Problème boucle while php : rien ne s'affiche
mugen
-
nEm3sis Messages postés 722 Statut Membre -
nEm3sis Messages postés 722 Statut Membre -
Bonjour,
j'ai un problème concernant php,
je voudrais insérer une boucle while mais il ne m'affiche rien !!! :(
Voici mon code :
<?php
$connection=mysqli_connect("localhost", "root", "", "prog");
$resultformation=mysqli_query($connection,"select * from formation ;");
while($rowformation = mysqli_fetch_array($resultformation))
{
echo $rowformation["ecole"]. "<br/>".$rowformation["specialite"]." <span class = "bold"> ".$rowformation["diplome"]."</span>"";
}
?>
Merci pour votre aide
j'ai un problème concernant php,
je voudrais insérer une boucle while mais il ne m'affiche rien !!! :(
Voici mon code :
<?php
$connection=mysqli_connect("localhost", "root", "", "prog");
$resultformation=mysqli_query($connection,"select * from formation ;");
while($rowformation = mysqli_fetch_array($resultformation))
{
echo $rowformation["ecole"]. "<br/>".$rowformation["specialite"]." <span class = "bold"> ".$rowformation["diplome"]."</span>"";
}
?>
Merci pour votre aide
A voir également:
- Problème boucle while php : rien ne s'affiche
- Easy php - Télécharger - Divers Web & Internet
- Expert php pinterest - Télécharger - Langages
- Boucle excel sans macro - Forum Excel
- Télé samsung s'éteint et se rallume en boucle - Forum Téléviseurs
- Mon pc s'allume et s'éteint en boucle ✓ - Forum Matériel & Système
1 réponse
1) tu a un " en trop a la fin
2) je ne suis pas sur mais ca ne macherai pas mieu avec des ' a la place des " ?
3) est-ce normal le ; ligne 4 ?
4) je ne connai pas mysqli donc dsl si jsuis pas sur
<?php
$connection=mysqli_connect("localhost", "root", "", "prog");
$resultformation=mysqli_query($connection,"select * from formation");
while($rowformation = mysqli_fetch_array($resultformation))
{
echo $rowformation["ecole"].'<br/>'.$rowformation["specialite"].' <span class = "bold"> '.$rowformation["diplome"].'</span>'";
}
?>
2) je ne suis pas sur mais ca ne macherai pas mieu avec des ' a la place des " ?
3) est-ce normal le ; ligne 4 ?
4) je ne connai pas mysqli donc dsl si jsuis pas sur
<?php
$connection=mysqli_connect("localhost", "root", "", "prog");
$resultformation=mysqli_query($connection,"select * from formation");
while($rowformation = mysqli_fetch_array($resultformation))
{
echo $rowformation["ecole"].'<br/>'.$rowformation["specialite"].' <span class = "bold"> '.$rowformation["diplome"].'</span>'";
}
?>