ce petit script m'affiche toujours ces problèmes:
Warning: mysql_fetch_array() expects parameter 1 to be resource, boolean given in C:\Program Files\EasyPHP-5.3.6.0\www\list_of_authors.php on line 31
Warning: mysql_fetch_array() expects parameter 1 to be resource, boolean given in C:\Program Files\EasyPHP-5.3.6.0\www\list_of_authors.php on line 38
Notice: Undefined variable: titre in C:\Program Files\EasyPHP-5.3.6.0\www\list_of_authors.php on line 44
Notice: Undefined variable: s_email in C:\Program Files\EasyPHP-5.3.6.0\www\list_of_authors.php on line 45
Notice: Undefined variable: login in C:\Program Files\EasyPHP-5.3.6.0\www\list_of_authors.php on line 45
Notice: Undefined variable: s_email in C:\Program Files\EasyPHP-5.3.6.0\www\list_of_authors.php on line 46
Notice: Undefined variable: s_password in C:\Program Files\EasyPHP-5.3.6.0\www\list_of_authors.php on line 46
et j'arrive pas à affiché les auteurs de chaque papier dans ma base de données
voici le script
<table width='100%' cellpadding='2' cellspacing='2' align='center' border='1'>
<tr align='center' bgcolor='#CCCCCC' style='font-weight:bold'>
<td width="10%" nowrap>Id Papier</td>
<td width="30%" nowrap>titre Papier</td>
<td width="30%"nowrap>mail</td>
<td width="20%" nowrap>password</td>
<td width="10%" nowrap>statut</td>
</tr></table>
<?php
if (isset($_SESSION['Admin']))
{
$linklast="Administrator";
include ("../data_st/dbsc.php");
$req12="select `a_num`, `a_email`,`id_soum`,`id_papier` from `auteur` ";
$resReq12=mysql_query($req12);
while($auteur=mysql_fetch_array($resReq12) )
{
$a_num=$auteur[0];
$a_email=$auteur[1];
$a_idsoum=$auteur[2];
$a_idpapier=$auteur[3];
$req13="select `login`,`password` from `auteur_log` where `a_num`=$a_num";
$resReq13=mysql_query($req13);
while($auteur_log=mysql_fetch_array($resReq13))
{
$login=$auteur_log[0];
$password=$auteur_log[1];
}
$req1="select `s_email`, `s_password` from `soum` where `soum`.`s_num`=`auteur`.`s_num`";
$resReq1=mysql_query($req1);
while($soum=mysql_fetch_array($resReq1) )
{
$s_email=$soum[0];
$s_password=$soum[1];
}
$req="select `p_num`,`titre`,`s_num` from `papier` where `papier`.`p_num`=`auteur`.`id_papier` ";
$resReq=mysql_query($req);
while($papier=mysql_fetch_array($resReq) )
{
$p_num=$papier[0];
$titre=$papier[1];
$s_num=$papier[2];
}
echo"<table align='justify' border='1'><tr><td width='10%' nowrap>$a_idpapier</td><td width='30%' nowrap>$titre</td>";
if ($login==$s_email)
echo"<td width='30%' nowrap>$s_email</td><td width='20%' nowrap>$s_password</td><td width='10%' nowrap>auteur</td></tr></table>";
else
echo"<td width='30%' nowrap>$login</td><td width='20%' nowrap>$password</td><td width='10%' nowrap>co-auteur</td></tr></table>";
}
}
?>
Cindrella