title: removing file extension from anywhere in the the url with htaccess
body: <p>I have the following lines in my htaccess file which makes <a href="http://mydomain.com/pages" rel="nofollow">http://mydomain.com/pages</a> work as if it were <a href="http://mydomain.com/pages.php" rel="nofollow">http://mydomain.com/pages.php</a></p>
  
  <pre><code>RewriteEngine On
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteRule ^([^\.]+)$ $1.php [NC,L]
  </code></pre>
  
  <p>HOWEVER</p>
  
  <p>my urls my look like this <a href="http://mydomain.com/pages/1234/SOMETHING" rel="nofollow">http://mydomain.com/pages/1234/SOMETHING</a> OR <a href="http://mydomain.com/pages/something/1/something" rel="nofollow">http://mydomain.com/pages/something/1/something</a> else etc.  ho do i remove the extension from pages not knowing what the rest of the length of my url will look like?</p>