Images loading on localhost but not using IP
<p>I am using a PHP script to read some folders in directory and based on their names retrieve their posters. All of this works fine on <code>localhost</code>. However, when opening externally, this does not work and results in <code>blank</code> images.</p>

<p>A screenshot from localhost:<img src="http://i.stack.imgur.com/qvqCe.jpg" alt="Screenshot of localhost">
<hr>
The problem can be found at <code>89.241.171.100/Prac/</code>.
PHP generating <code>img tag</code>:</p>

<pre><code>while (false !== ($entry = readdir($handle))) {
      $counter++;
      echo "&lt;span class='title'&gt;
              &lt;img src='holder.js/200x280/text:$entry' 
                   alt='$entry' 
                   onload='loader(this, \"$entry\")' /&gt;
                   &lt;/span&gt;";
      if($counter == 5) break;
 }
</code></pre>

<p>PHP fetching the src for the images called via ajax from <code>loader()</code>:</p>

<pre><code>if($_POST['title']) {
    $title = $_POST['title'];
    $imdb = new Imdb();
    $movieArray = $imdb-&gt;getMovieInfo("$title");
    $link = $movieArray["poster_large"];
    echo $link;
}
</code></pre>

<p><code>Loader()</code> function:</p>

<pre><code>$.ajax({
     type: 'post',
     url: 'loader.php',
     data: 'title='+title,
     success: function(data) {
          img.src = data;
     }
 });
</code></pre>
