I need to rewrite a URL so when this is called http://localhost/asset/?id=n the internal 'expression' should look like the following http://localhost/asset.php/?id=n (where n is a integer).
I have tried
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^asset/?id=([0-9]+)$ asset.php?id=$1
but it simply does not work due to ?id= not acting like a string.
I'm very new to RewriteRule and Apache config itself so any help would really be appreciated.
Thanks,