Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Other HTACCESS configure Reply To: HTACCESS configure

#183112
__
Participant

Just to clarify, your website needs URLs like this:
http://example.com/page/index.php?id=63

and you want to be able to use URLs like this instead:
http://example.com/page/63

Correct?

The rule you have above would cause an infinite loop. You rewrite “anything” after page/ into “index.php” with a query string… however, “index.php” does qualify as “anything,” so it will trigger the rule again.

Really, you’re look for one or more digits, aren’t you?

RewriteEngine On
RewriteRule page/(\d+)$ /page/index.php?id=$1 [L]