F
F
Fwwll2017-11-08 16:33:13
Apache HTTP Server
Fwwll, 2017-11-08 16:33:13

Change mysite.com/pages/page.html to mysite.com/page.html without redirect?

Let's assume that the "page.html" file is available at https://mysite.com/pages/page.html to the root? PS: if this is important, then taking into account the fact that .htaccess uses Rewrite for cnc RewriteEngine On RewriteCond %{SCRIPT_FILENAME} !-d RewriteCond %{SCRIPT_FILENAME} !-f RewriteRule ^(.*)$ ./index.php?route =$1

Answer the question

In order to leave comments, you need to log in

1 answer(s)
F
Fwwll, 2017-11-13
@adrontek

I asked myself, I'll answer it myself
RewriteEngine On
RewriteRule ^([a-zA-Z0-9_-]+)\.html$ ./pages/$1\.html

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question