title: Regex for clean URLs
body: <p>Clean URLs seem pretty simple but I'm in need of a special situation. I would like to be able to include the .html suffix or nothing at all but not any other extension:</p>
  
  <pre>
  someurl = pass
  someurl/somepage = pass
  someurl.html = pass
  someurl/somepage.html = pass
  
  someurl.css = fail
  someurl.exe = fail
  someurl.anyotherextension = fail
  someurl/someother.ext = fail
  </pre>
  
  <p>Is this possible? Would I have to somehow exclude the extensions I don't want?</p>
  
  <p>Edit:</p>
  
  <p>None of the answers so far seem to work. The only thing that I've discovered on my own that works is:</p>
  
  <p><pre>^/([\w]*(.html)?)$</pre> but it will not work with slashes in the url. Adding a slash inside the character class brackets makes it fail.</p>