title: PHP Regular Expression NOT starting with.. negative lookbehind not working?
body: <p>I am trying to extract a nameserver.
  The format of <code>$output</code> is such that it contains <code>ns1.nameserver.com</code> for example.</p>
  
  <p>It might also contain <code>www.apple.com</code>.<br>
  This is not a nameserver of course.</p>
  
  <p>I am trying to not include any results therefore which contain <code>www.</code><br>
  My attempt is below:</p>
  
  <pre><code>$regexp = "/(?&lt;!www)([A-Za-z0-9-]+[\.][A-Za-z0-9-]+[\.][A-Za-z0-9-\.]+)/i";
  preg_match_all($regexp, $output, $nameservers);
  </code></pre>