Unable to view images in php : <p>I am unable to view images on my webserver in <code>php</code> and I keep getting <code>server 500</code> error.</p>

<p>I believe that it is this line of code <code>echo "&lt;img src='$row["sourchPath"]'&gt;"</code>:</p>

<pre><code>while ($row = mysqli_fetch_assoc($result)){
    if($row){
        echo $row["sourchPath"]; // this works
        echo "&lt;img src='$row["sourchPath"]'&gt;";
    }
    else {
        echo "error";
    }
}
</code></pre>

<p>My file directory is like <code>images/football.jpg</code></p>
