0

Hello the id that im getting is "$id" instead of the int id what i would like to happen is that basically it will go to the full size of the image in the "showImage.php"

<?php
while($row = mysqli_fetch_array($result)) {
    $id = $row[0];


echo "<tr>";

    echo "<td>".$row[0]."</td>";
echo "<td>".$row[1]."</td>";
echo "<td>".$row[2]."</td>";
echo "<td>".$row[3]."</td>";
echo "<td>".$row[4]."</td>";
echo "<td>".$row[5]."</td>";
echo "<td>".$row[7]."</td>";
echo "<td>".$row[8]."</td>";
echo "<td>".$row[9]."</td>";
echo "<td>".$row[10]."</td>";
  echo '<td>
 <a href="showImage.php?id=$id"> <img id="$id" src="data:image/jpeg;base64,'.base64_encode($row[11] ).'" height="200" width="200"  /> </a> 
                           </td>  ';
?>

in case you're wondering this is the html

<tr>
<th>ID</th>
<th>Voter's ID</th>
<th>Username</th>
<th>Password</th>
<th>Email</th>
<th>Confirmation Code</th>
<th>UserType </th>
<th>Age</th>
<th>Gender</th>
<th>Birthday</th>
<th>Action</th>
<th>Image</th>
<tr>
Valkyrja
  • 41
  • 8
  • 1
    Possible duplicate of [What is the difference between single-quoted and double-quoted strings in PHP?](https://stackoverflow.com/questions/3446216/what-is-the-difference-between-single-quoted-and-double-quoted-strings-in-php) – user3942918 Aug 09 '17 at 17:52
  • `echo ' '` – HTMHell Aug 09 '17 at 17:55
  • thank you so much :) its fixed now i guess i need to study that difference between double quote and single quote – Valkyrja Aug 09 '17 at 17:57

0 Answers0