title: PHP: Getting url variable with preg_match?
body: <pre><code>http://www.example.com?id=05
  </code></pre>
  
  <p>or</p>
  
  <pre><code>http://www.example.com?id=05&amp;name=johnny
  </code></pre>
  
  <p>This is a string. And I want to get the value of <code>$id</code> from it.</p>
  
  <p>What is the correct pattern for it?</p>