Www/no-www redirect


#1

Just a suggestion, maybe it would be worthwhile to add redirect option to the nginx conf i.e.

server {  
    listen       80;  
    server_name  example.org;  
    return       301 http://www.example.org$request_uri;  
}  

server {  
    listen       80;  
    server_name  www.example.org;  
    ...  
}

#2

@piotrseefeld

We have covered all redirects here - https://rtcamp.com/tutorials/nginx/www-non-www-redirection/

Please let me know if you have any suggestion.


#3

Hmm.. can't get it to work. www.domain.com does not work, website is only loading when called without www... Any suggestion please?


#4

Cross check WordPress Address (URL) & Site Address (URL) in http://domain.com/wp-admin/options-general.php and make sure its looks like http://www.domain.com


#5