title: .htaccess rewrite rules
body: <p>I'm trying to get the following effect:</p>
  
  <ol>
  <li>A user visits example.com/profile/Tom and it, in the background, makes it example.com/profile.php?username=Tom</li>
  <li>Instead of making line after line of .htaccess for each URL (Figure 1), I want it to be short and work nicely, e.g. the user visits example.com/about and it uses about.php, then example.com/helloworld and it uses helloworld.php</li>
  </ol>
  
  <p>As right now, I have to put the following for each URL I want, and instead I want 2-3 lines of .htaccess that would do the job. (If possible, more is fine, I'm not great with .htaccess)</p>
  
  <pre><code>RewriteRule ^login/submit$ login.php?action=submit
  </code></pre>