php - htaccess Redirect to another subfolder if URL contains blog in it -
i have sub folder named "blog" inside public_html.
if url contains blog in either "blog.mydomain.com" or mydomain.com/blog, want redirect mydomain.com/blog/index.php.
the problem using silversrtipe 3.x , have page created name "blog" whenever try mydomain.com/blog instead of redirecting mydomain.com/blog/index.php opens silverstripe page.
how can redirect mydomain.com/blog "mydomain.com/blog/index.php"?
any appreciated.
thanks
you can place rule first rule:
rewritecond %{http_host} ^blog\. [or] rewritecond %{request_uri} ^/blog [nc] rewriterule ^ /blog/index.php [l]
Comments
Post a Comment