Si inferieur à 4.3.3 essaye ça
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
27
28
29
30
31
32
33 function afficher_msg($i,$iinit,$result) { while ($ligne=mysql_fetch_array($result,MYSQL_NUM) and $i-10<0) { $i++; echo "<tr>"; $date=$ligne[0]; $reste=NULL; $format="%d-%d-%d-%s"; sscanf($date,$format,$year,$month,$day,$reste); $date=$day."-".$month."-".$year; if (isset($reste)) { $date .= "-".$reste; } echo "<td valign=top width=120>".nl2br($date)."</td>"; echo "<td align=left valign=top width=120>".str_replace('<', '>',str_replace('>', '<',nl2br(html_entity_decode($ligne[1]))))."</td>"; echo "<td>".nl2br($ligne[2])."</td>"; echo "</tr>"; } echo "</table>"; }
Partager