title: Remove .php extensions with web.config on IIS7
body: <p>I have an <strong>.htaccess</strong> file which removes the .php extension from files, converting for example <em>so.com/question.php</em> to <em>so.com/question</em>, and also redirecting the index file in the folder, e.g. <em>so.com/answer/index.php</em> redirects to <em>so.com/answer/</em> exactly as described <a href="https://stackoverflow.com/a/9635748/310174">in this answer</a></p>
  
  <p>I have just set up my site locally on IIS7 and need to recreate the same behaviour in a <strong>web.config</strong> but don't know where to start with converting/rewriting the .htaccess file.</p>