title: Regex - get href value from a tag
body: <p>I want to get value from a href.</p>
  
  <p>Here is the HTML I am working with:</p>
  
  <pre><code>&lt;div class="streeet"&gt; 
    &lt;b&gt;Name:&lt;/b&gt;wwww&lt;br /&gt;
    &lt;b&gt;Post Code:&lt;/b&gt;97
    &lt;b&gt;City:&lt;/b&gt;
    &lt;a href="/bar-fan-pers.html" title="abcd"&gt;VALUE&lt;/a&gt; 
    &lt;br /&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>I am trying to use <code>preg_match_all</code>:</p>
  
  <pre><code>preg_match_all('/&lt;div\s*class=\"walldetsleft\"&gt;[^&gt;]*&lt;a\s*href=\"[^&gt;]*\"\s[^\&gt;]*&gt;(.*?)&lt;\/a&gt;/', $url, $val);
  </code></pre>
  
  <p>It does not work - the output is just an empty array. How can I write a regex to do this?</p>