title: Allow multiple URI parameters through regex
body: <p>I'm pretty close from what I want to achieve.</p>
  
  <p>I have this :</p>
  
  <pre><code>'/create-group/([A-Za-z0-9\-\_]+)(?:/([A-Za-z0-9\-\_]+))?(?:(\?|&amp;)(groupid|copyofgroup|ref)=([A-Za-z0-9\-\_]+))?'
  </code></pre>
  
  <p>It allows me to restrain what URIs can be typed in and accessed, such as:</p>
  
  <pre><code>/create-group/123/456?groupid=789
  </code></pre>
  
  <p>In the last bit of the regex, I allow 3 parameters (groupid, copyofgroup and ref).</p>
  
  <p>This is all good, but I can't figure out a way to have my preg_match validate an <strong>infinite</strong> number of these 3 parameters. Right now, I'm only limited to 1 instance of a parameter.</p>
  
  <p>I'd like my preg_match() to accept :</p>
  
  <pre><code>/create-group/123/456?groupid=789&amp;ref=101112&amp;copyofgroup=789
  </code></pre>
  
  <p>I've tried multipliers such as <code>*</code> and <code>+</code>, but to no avail.</p>
  
  <p>Thank you!</p>