title: simpleHTMLdom - Using multiple URLs from an array
body: <p>In my UI there is a text area that has a list of URLs separated by new line.</p>
  
  <p>I am getting this into a string and exploding it using newline character. I am getting this error:</p>
  
  <blockquote>
    <p>Fatal error: Call to a member function find() on a non-object in C:\xampp\htdocs\apps\lt\track-them.php on line 34</p>
  </blockquote>
  
  <pre><code>$myurl       = "http://mydomain.com/testpage1.html";
  $str         = "http://www.domain.com/page1.html
  http://www.homepage.com/page2.html
  http://www.internet.com/index.html";
  
  $backlinkarr = explode("\n", $str);
  echo '&lt;table border=1&gt;';
  foreach ($backlinkarr as $backlinkitem) {
      $backlinkitem = trim($backlinkitem);
      $LinkCount    = 0;
      $html         = file_get_html($backlinkitem);
      foreach ($html-&gt;find('a') as $link) {
          if ($link-&gt;href == $myurl) {
              $LinkCount += $LinkCount + 1;
          }
      }
      echo $backlinkitem . ' (' . $linkCount . ')';
  }
  </code></pre>