title: How do you use a regex in a htaccess file?
body: <p>I created a regex <code>[0-9]{1,10}[-][0-9a-z]{5,9}</code> to find 1 to 10 numbers followed by a dash followed by 5 to 9 numbers and lowercase letters, and as far as I can tell its working. But how do I use it in a htaccess file to mask URLs from <a href="http://website.com/realpage.php?id=00000-a0a0aaa0" rel="nofollow">http://website.com/realpage.php?id=00000-a0a0aaa0</a> to <a href="http://website.com/00000-a0a0aaa0" rel="nofollow">http://website.com/00000-a0a0aaa0</a>.</p>
  
  <p>The rule I'm using at the moment is...</p>
  
  <pre><code>RewriteRule /[0-9]{1,10}[-][0-9a-z]{5,9}/?$ realpage.php?id=$1 [QSA,L]
  </code></pre>
  
  <p>...but it doesn't seem to be working.</p>