Reputation: 163
I wrote this rule in .htaccess:
RewriteRule /(\d+)*$ ./index.php?id=$1
But in case "http://myfunnydomain.hu/123" I get the mesage: 'The requested URL /123 was not found on this server.'
So what is wrong? :)
Thank you, M
Upvotes: 0
Views: 20
Reputation: 411
The URI does not start with a /
. To mark the start of the URI, use a ^
. This is the character used in regular expressions to mark the start of a string. You can read a detailed explanation about start and end of string/line anchors over here
RewriteRule ^(\d+)*$ ./index.php?id=$1
Upvotes: 1