title: .htaccess url rewrite GET parameter and remove .php without breaking javascript/css
body: <p><strong>Sorry if I explain my problem badly, It's a little hard to explain what's going wrong*</strong><br>
  I've been playing around with the <code>.htaccess</code> file for a while now, Trying to get this to work.<br>
  I have the following files in my website directory:  </p>
  
  <pre><code>- index.php
  - generator.php
  - menu.php
  - gift-history.php
  - stats.php
  
  - images/
      - bg-stars.png
      - avatar.png
  
  - css/
      - style.css
      - glow.css
      - background.css
  
  - js/
      - script.js
      - jquery.js
      - destiny.js
      - snowflake.js
  </code></pre>
  
  <p>The three folders are <code>images,css and js</code>.<br>
  The generator.php requires a <code>$_GET</code> paremeter to know what generator to load.<br>
  So far, i've been using the following url:<br>
  <code>http://tryhardhusky.com/generator.php?t=destiny</code><br>
  For the other pages, I have the following code in my <code>.htaccess</code> file:  </p>
  
  <pre><code>php_value display_errors Off
  php_flag magic_quotes 1
  php_flag magic_quotes_gpc 1
  php_value mbstring.http_input auto
  php_value date.timezone America/New_York
  Options +FollowSymLinks -MultiViews
  # Turn mod_rewrite on
  RewriteEngine On
  RewriteBase /
  ## hide .php extension snippet
  # To externally redirect /dir/foo.php to /dir/foo
  RewriteCond %{THE_REQUEST} ^[A-Z]{3,}\s([^.]+)\.php [NC]
  RewriteRule ^ %1 [R,L]
  # To internally forward /dir/foo to /dir/foo.php
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteCond %{REQUEST_FILENAME}.php -f
  RewriteRule ^(.*?)/?$ $1.php [L]
  </code></pre>
  
  <p>This pretty much removes the <code>.php</code> extension from the file name, So files that would be:<br>
  <code>http://tryhardhusky.com/gift-history.php</code><br>
  becomes:<br>
  <code>http://tryhardhusky.com/gift-history</code>  </p>
  
  <p>I'm trying to get the following page:<br>
  <code>http://tryhardhusky.com/generator.php?t=destiny</code><br>
  to rewrite as<br>
  <code>http://tryhardhusky.com/generator/destiny</code>  </p>
  
  <p>All my previous attempts have broken the js and css, Returning a 404 error when loading the page (despite the location being correct)<br>
  [Error 404 Not Found: <a href="http://tryhardhusky.com/js/jquery.js" rel="nofollow">http://tryhardhusky.com/js/jquery.js</a> ]  </p>
  
  <p>Any clue how I can do this without breaking it?</p>