title: Regex to turn url into a clean page title
body: <p>I use <code>$_SERVER['REQUEST_URI']</code> to get this <code>/res/about_us.php</code>, I want the output to be <code>About Us</code>, I know I can use <code>preg_replace</code> for this, it is the regular expression I am struggling with.</p>
  
  <p>I have this pitiful attempt thus far:</p>
  
  <pre><code>echo str_replace('.php', '', $uri);
  </code></pre>
  
  <p>I realised after this that I cant replace two cases using str_replace... So I thought I need preg_replace with regex, but not a clue how it works, cant seem to find a similar example through Google.</p>
  
  <p>Regards</p>