• Introducing WebPros Cloud - a fully managed infrastructure platform purpose-built to simplify the deployment of WebPros products !  WebPros Cloud enables you to easily deliver WebPros solutions — without the complexity of managing the infrastructure.
    Join the pilot program today!
  • Support for BIND DNS has been removed from Plesk for Windows due to security and maintenance risks.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS.

Redirect www.[name].com domain to [name].com domain

O

open4biz

Guest
When I set up my domains in Plesk, I set them up so they did not need the www in front of the domain name (i.e. www.mydomain.com).

Now I would like to make it idiot proof and send the user that mistakenly types www to the www-less domain name. Would you do that with the DNS setup section of the domain control panel?

I set up cname records for all three of my domains (www.blah.com automatically goes to blah.com)... but the third doesn't seem to be working. Which got me to thinking, did I do it correctly? Is that the technically correct way? Or should I use a redirect script?

Any help would be appreciated. :p
 
.htaccess file

Try using an .htaccess file using the following paramaraters.


# permanently redirect from www domain to non-www domain
RewriteEngine on
Options +FollowSymLinks
RewriteCond %{HTTP_HOST} ^www\.INSERTDOMAINNAMEHERE\.com$ [NC]
RewriteRule ^(.*)$ http://INSERTDOMAINNAMEHERE.com/$1 [R=301,L]

# redirect a specific file via 301
redirect 301 /INSERT_URL_HERE.html http://INSERTDOMAINNAMEHERE.COM

#save this file as .htacess
#in your httpdocs file it should then
#redirect to the domain of your choice.

-Chris
 
Try using an .htaccess file using the following paramaraters.


# permanently redirect from www domain to non-www domain
RewriteEngine on
Options +FollowSymLinks
RewriteCond %{HTTP_HOST} ^www\.INSERTDOMAINNAMEHERE\.com$ [NC]
RewriteRule ^(.*)$ http://INSERTDOMAINNAMEHERE.com/$1 [R=301,L]

# redirect a specific file via 301
redirect 301 /INSERT_URL_HERE.html http://INSERTDOMAINNAMEHERE.COM

#save this file as .htacess
#in your httpdocs file it should then
#redirect to the domain of your choice.

-Chris

Hi 64bithost.com, I am struggling to get this to work. I have tried various methods ref. :http://forum.parallels.com/showthread.php?t=88372

Are you able to offer any suggestions?

DM.
 
Back
Top