while ($data = mysql_fetch_array($result)){

                            echo "<tr bgcolor='$result2'>";
                            echo '<td>'.$data['image'].'</td>';
                            echo '<td>'.$data['path'].'</td>';
                            echo '<td>'.<img src="photos/image".$i>.'</td>';
                            echo '<td><a href="admin.php?mode=delete&id='.$data['id'].'">Hapus</a> |<a href="input_image.php?id='.$data['id'].'">Edit</a></td>';
                        echo '</tr>';


What is this:

Parse error: syntax error, unexpected '<' in C:\xampp\htdocs\Bread\administrator\image_gallery.php on line 153

            line: 153       echo '<td>'.<img src="photos/image".$i>.'</td>';

Recommended Answers

All 4 Replies

This line

echo '<td>'.<img src="photos/image".$i>.'</td>';

Should be

echo '<td><img src="photos/image"'.$i.'></td>';


echo "<td><img src='photos/image$i'></td>";

echo "<td>"."<img src='photos/image'."$i>"."</td>"
try it like this .
you get the error your string concatenation is not correct.

error in "

 echo ('<td><img src="photos/image'.$i.' /></td>');

you have a missing " from your img tag

echo ('<td><img src="photos/image'.$i.' "/></td>');
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.