I've got a php file called author.php which will pull a record from a db dependent on a given id in the URL. HOwever, I want to be able to access them like this instead:
/authors/1
Here's what I've got in my .htaccess:
I'm not very well up on regex so I'm not too sure what I'm doing wrong. What I thought I was saying was that anything that had a url authors/idhere would be passed as author.php?iidhere but it doesn't seem to work. Can somebody help me oout a bit?
/authors/1
Here's what I've got in my .htaccess:
Code:
RewriteEngine on
RewriteBase /beta
RewriteRule ^authors/*$ author.php?$1 [T=application/x-httpd-php]
I'm not very well up on regex so I'm not too sure what I'm doing wrong. What I thought I was saying was that anything that had a url authors/idhere would be passed as author.php?iidhere but it doesn't seem to work. Can somebody help me oout a bit?