Search the Community
Showing results for tags 'php query database'.
-
I am trying to make the query work in my php script ,that allow me to echo all speciality related to the user sing in,but it doesn't give me nothing this is my query : there's Table"affecte" tha has a link between Table"enseignat" and "groupe" and in Table "groupe" there's link to Table "speciality" this images of every table like you see in the script and every time I click on the list it don't give me nothing first of all I've tried this one: <ul class="nostart"> <select name="select" class="textfields" id="Speciality"> <option id="0">-- Select Speciality --</option> <?php $getallSpeciality = mysql_query("select Nom_Specialite from specialite where enseignant.Id_enseignant=''+mail+''' and enseignant.`Id_Enseignant`=affecte.`Id_Enseignant` and affecte.`Id_Groupe`=groupe.`Id_Groupe` and specialite.`Id_Specialite`=groupe.`Id_Specialite`;"); while($viewallSpeciality = mysql_fetch_array($getallSpeciality)){ ?> <option id="<?php echo $viewallSpeciality['Id_Specialite']; ?>"> <?php echo $viewallSpeciality['Nom_specialite'] ?></option> <?php } ?> </select> </ul> select Nom_Specialite from specialite,enseignant,affecte,groupe where enseignant.mail_enseignant=''+mail+''' and enseignant.`Id_Enseignant`=affecte.`Id_Enseignant` and affecte.`Id_Groupe`=groupe.`Id_Groupe` and specialite.`Id_Specialite`=groupe.`Id_Specialite`; UPDATE evaluation SET Td='11' WHERE Matricule='1' www2.0zz0.com/2014/04/28/01/167085039.jpg www2.0zz0.com/2014/04/28/01/793102561.jpg www2.0zz0.com/2014/04/28/01/324938650.jpg i want to displaye speciality that linked to enseignant ! ,and if tried SELECT * FROM specialite it giving all the speciality ,but what I am trying to do is to echo for every enseignant "user" his speciality ,my login.php is in a separate file and this code is from my note-on.php ,I will very grateful for any help thanks in advance !