You want www.domain.com/Page1
appear in the address bar of the browser, but inside this URL should be /page.php?i=Page1
. In this case, the problem is completing /
in your regex:
Rewriterule ^([a-zA-Z0-9_-]+)/$ page.php?i=$1 ^---here
Your desired URL /Page1
does not have a trailing slash, but rewrite requires one for the regex, so the pattern doesn't match and rewriting doesn't happen. Try removing /
and see if this helps:
Rewriterule ^([a-zA-Z0-9_-]+)$ page.php?i=$1 ^---no /
source share