这是我的源代码。
<?php
include "koneksi.php";
$datatamu= mysql_query("select judul_gambar,nama_file from gambar order by judul_gambar asc");
echo "
<table>
<tr>
<th>judul_gambar</th>
<th>gambar</th>
</tr>";
while($rec=mysql_fetch_object($datatamu)){
echo "<tr>";
echo "<td>".$rec->judul_gambar."</td>";
echo "<td";
echo "<img src='.$rec->nama_file.' alt='.$rec->judul_gambar' title='.$rec->judul_gambar' width='100'>";
echo "</td>";
echo "</tr>";
}"
</table>";
mysql_close();
?>
我正在与源代码在同一目录上创建一个文件夹 gambar。这是数据库
id_gambar:Int[5]
judul_gambar:varchar[25]
nama_file:varchar[25]
对不起,如果我的英语不好。:)