Htaccess folder rewrite folder to file?

Htaccess folder rewrite folder to file?

Here is how you can rewrite pages that are inside a folder. It also works in wordpress.

1
RewriteRule ^phones/phone-page-(.*).html /phones/index.php?page=$1 [L]

In the example, “phones” is the folder. https://incvice.com/phones and /phones/index.php is the actual page (located in the /phones/ subfolder).

This will work, just add the code inside your .htaccess file.

Add a comment: