Bonjour,

je vous demande de l'aide, j'ai besoin d'afficher des données contenu dans 2 tables

j'ai fait un script qui ne fonctionne pas, j'ai une erreur de syntaxe sur la dernière ligne avant ?>
Parse error: syntax error, unexpected $end in /data/ftp/aisne/www/adherents/liste_transac.php on line 25

il y a un champ identique sur les deux bases--> id_adh
Merci d'avance
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
<?php
 
include("_connect.php"); // connexion seveur et bdd
$table1="galette2_transactions"; // Nom de la table1
$table2="galette2_adherents"; // Nom de la table2
 
$sql="SELECT * FROM $table1,$table2 WHERE $table2.id_adh = $table1.id_adh ORDER BY trans_date";
$rs =mysql_query($sql);
 
while ($ligne=mysql_fetch_array($rs,MYSQL_ASSOC))
{
$id_adh = $ligne['id_adh'];
$numero_adh = $ligne['numero_adh'];
$nom_adh = $ligne['nom_adh'];
$trans_date = $ligne['trans_date'];
$trans_amount = $ligne['trans_amount'];
$trans_desc = $ligne['trans_desc'];
 
$html="<tr>";
$html.="<td>$id_adh</td><td>$numero_adh</td><td>$nom_adh</td><td>$trans_date</td><td>$trans_amount</td><td>$trans_desc</td></tr>";
 
echo $html;
 
}
 
?>