title: Using PHP to return results from HTML page
body: <p>If I have the following HTML code:</p>
  
  <pre><code>&lt;ul&gt;
    &lt;li&gt;
      &lt;a href="/link1/"&gt;link 1&lt;/a&gt;
    &lt;/li&gt;
    &lt;li&gt;
      &lt;a href="/link2/"&gt;link 2&lt;/a&gt;
    &lt;/li&gt;
  ...
  &lt;/ul&gt;
  </code></pre>
  
  <p>How can I use PHP to return an array containing the contents of all the href's?</p>
  
  <p>ex:</p>
  
  <pre><code>$array[0]="/link1/";
  $array[1]="/link2/";
  </code></pre>
  
  <p>and so on.</p>