title: Better way to write multiple strpos calls
body: <p>I've made a simple script that finds all of the outgoing <code>&lt;a&gt;</code> tags of a website, and displays them.</p>
  
  <p>To do this first I scrape the sitemap, put those URLs into an array, then loop through the URLs scraping each one individually looking for <code>&lt;a&gt;</code> tags, I then run <code>strpos()</code> on each found tag see if its got any URLs that I want to ignore. </p>
  
  <p>The script takes about 5 minutes (500 pages scraped) to complete (running locally) and I was wondering if there was a quicker way to handle the needle/haystack search for excluded params. At the moment I'm using </p>
  
  <pre><code>//SEES IF URL CONTAINS EXCLUDED PARAM
  function find_excluded_url ($match_url) {
      return strpos($match_url, "mydomain.co.uk") ||
          strpos($match_url, "tumblr.com") ||
          strpos($match_url, "nofollow") ||
          strpos($match_url, "/archive") || 
          strpos($match_url, "page/2");
  }
  </code></pre>
  
  <p>To then display the result im using </p>
  
  <pre><code>if ( find_excluded_url($element) == false ) {
     echo "&lt;a href='$element-&gt;href'&gt;" . $element-&gt;href . "&lt;/a&gt;";
  } 
  </code></pre>
  
  <p>Is there a more performant way to achieve this? </p>
  
  <p>Sorry if this is a very obvious question, this is the first real thing I've built with PHP</p>