\r
function Panel($participant)\r
{\r
- $this->participant;\r
+ $this->participant = $participant;\r
}\r
\r
function rendre()\r
{
# selection de tous les participants
- $res_SQL = mysql_query("SELECT pseudo FROM participants ORDER BY id");
+ $res_SQL = pg_query("SELECT pseudo FROM participants ORDER BY id");
- echo '<div id="nbParticipants"><em>', mysql_num_rows($res_SQL), '</em> inscrit', (mysql_num_rows($res_SQL) > 1 ? 's' : ''), '</div>';
+ echo '<div id="nbParticipants"><em>', pg_num_rows($res_SQL), '</em> inscrit', (pg_num_rows($res_SQL) > 1 ? 's' : ''), '</div>';
# affichage des participants
- if (mysql_num_rows($res_SQL) > 0)
+ if (pg_num_rows($res_SQL) > 0)
echo '<ul id="participants">';
- for ($i=0; $i<mysql_num_rows($res_SQL); $i++)
+ for ($i=0; $i<pg_num_rows($res_SQL); $i++)
{
- mysql_data_seek($res_SQL, $i);
- $le_participant_pseudo = mysql_fetch_object($res_SQL);
+ pg_data_seek($res_SQL, $i);
+ $le_participant_pseudo = pg_fetch_object($res_SQL);
echo '<li>', traitement_pre_affichage($le_participant_pseudo->pseudo, 8), '</li>';
}
- if (mysql_num_rows($res_SQL) > 0)
+ if (pg_num_rows($res_SQL) > 0)
echo '</ul>';
if($this->participant->valide)
echo'
<form method="post" action="index.php?';
- foreach($HTTP_GET_VARS as $nom => $valeur)
+ foreach($_GET as $nom => $valeur)
echo $nom,'=',$valeur,'&';
echo'">
</form>';
}
else
- {
- if (isset($log)) echo '<em>[erreur de loggation]</em>';
-
+ {
echo'
<form method="post" action="index.php?';
- foreach($HTTP_GET_VARS as $nom => $valeur)
+ foreach($_GET as $nom => $valeur)
echo $nom,'=',$valeur,'&';
echo'">