Mobile app version of vmapp.org
Login or Join
Gail5422790

: .htaccess 301 Redirect How do I make it so all traffic is directed for the entire site and all subdirectories from non-www to www. Here is my .htaccess contents: RewriteEngine on <IfModule

@Gail5422790

Posted in: #301Redirect #Htaccess #NoWww

How do I make it so all traffic is directed for the entire site and all subdirectories from non-www to
Here is my .htaccess contents:

RewriteEngine on

<IfModule mod_suphp.c>
suPHP_ConfigPath /home/vivalast
<Files php.ini>
order allow,deny
deny from all
</Files>
</IfModule>

RewriteCond %{HTTP_HOST} ^example.com$
RewriteRule ^(.*)$ "http://www.example.com/" [R=301,L]

10.01% popularity Vote Up Vote Down


Login to follow query

More posts by @Gail5422790

1 Comments

Sorted by latest first Latest Oldest Best

 

@Tiffany637

Try this:

RewriteEngine on
RewriteCond %{HTTP_HOST} ^example.com [NC]
RewriteRule ^(.*)$ www.example.com/ [R=301,NC]

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme