I\'m new to rewriting urls and wanted to know how i would rewrite
From this /profile/4
To this /profile.php?id=4
I have this rule so far
You are pretty much there. Try using this instead
RewriteRule ^profile/(.*)$ profile.php?id=$1
I found this good free resource online to help you test your rewrite rules before you post them to your live site. This may help for the future. It looks like your rule should work as you have it posted though. The problem must be somewhere else.
Your rule is just fine so there's a redirection somewhere conflicting with it. I suppose that you don't have a real directory at /profile/4
so they main candidate left is mod_negotiation. Try this:
Options -MultiViews