Www. & Non-www versions problem
-
I currently have both WWW and non-WWW versions of my site live on the web, and I want to be able to have all non-WWW to point to WWW.http://nile-cruises-4u.co.ukhttp://www.nile-cruises-4u.co.uk
I want just the WWW version of the site live.I'm wondering the best way to resolve this?Is it normally dealt with in the .htaccess file and I think, looks like this but I'm not sure:<code>RewriteCond %{HTTP_HOST} !^www\. RewriteRule ^(.*)$ [http://www.](http://www.)%{HTTP_HOST}/$1 [R=301,L]</code>
-
Hi Colin,
Login to wordpress admin panel then go to setting -> General and in that change put
WordPress Address (URL) = http://www.nile-cruises-4u.co.uk/ and
Site Address (URL) = http://www.nile-cruises-4u.co.uk/
Hope this helps you...
-
Thanks to Sanket I've successfully managed to have the site show only www. and not the non-www. versions.
However I have a blog on the site and that still shows the non-www. version, for example:
http://nile-cruises-4u.co.uk/blog/makadi-palace-hotel-makadi-bay/
I wonder if anyone has come upon the same problem and what the solution might be?
Thanks,
Colin
-
Thank you very much Sanket.
That's so kind of you.
Colin
-
Hi Nile,I have made code for you... please this code in .httaccess fileRewriteEngine onRewriteRule ^([A-Za-z0-9-]+)/?$ index.cfm?id=$1 [L]Rewritecond %{http_host} ^nile-cruises-4u.co.uk/$ [nc]rewriterule ^(.*)$ http://www.nile-cruises-4u.co.uk/$1 [r=301,nc] RewriteRule ^index.cfm http://www.nile-cruises-4u.co.uk/ [L,R=301]
Hope this help you out.....
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
301 Redirects to relative URLs not absolute a problem?
Hi we recently did a migration and a lot of content changed locations see: https://d.pr/i/RvqI81 Basically, the 301 goes to the correct location but its a relative URL (as you can see from the screenshot) rather than absolute URL. Do you think this is a high priority issue from an SEO standpoint, should we get the developer to change the redirects to absolute? Cheers.
Intermediate & Advanced SEO | | cathywix0 -
Title & Keywords
Hi Quick question on arrangement of keywords in titles. I know the order isn't so important anymore, but would there be a real issue if I want to rank for 'Henry Xtra' but my title reads 'Numatic Henry Xtra Vacuum Cleaner' Rather than 'Henry Xtra Vacuum Cleaner' ?? Will it really make much difference? Thank you!
Intermediate & Advanced SEO | | BeckyKey0 -
Pagination & duplicate meta
Hi I have a few pages flagged for duplicate meta e.g.: http://www.key.co.uk/en/key/workbenches?page=2
Intermediate & Advanced SEO | | BeckyKey
http://www.key.co.uk/en/key/workbenches I can;t see anything wrong with the pagination & other pages have the same code, but aren't flagged for duplicate: http://www.key.co.uk/en/key/coshh-cabinets http://www.key.co.uk/en/key/coshh-cabinets?page=2 I can't see to find the issue - any ideas? Becky0 -
Bigcommerce & Blog Tags causing Duplicate Content?
Curious why moz would pick up our blog tags as causing duplicate content, when each blog has a rel canonical tag pointing to either the blog post itself and on the tag pages points to the blog as a whole. Kinda want to get rid of the tags in general now, but also feel they can add some extra value to UX later on when we have many more blog posts. Curious if anyone knows a way around this or even a best solution practice when faced with such odd issues? I can see why the duplicate content would happen, but when grouping content into categories?
Intermediate & Advanced SEO | | Deacyde0 -
Reviewing Category & Tag policy - Update
I recently (http://moz.com/community/q/less-tags-better-for-seo) started reviewing my category and tag policy, and things have been going very well. I thought I would share what I have done: Removed all tags from site Added unique descriptions for each post for the category excerpt. Only had the category description on the first page and use the description like a post to summarise and interlink to sub-categories or posts. This keeps pages from slipping down the number of clicks until it can be reached, improving link juice distribution. I also reduced the number of posts showing to 5, to allow more focus on the description (main part) of the category post. To add the category description on the first category page only in Wordpress, you need to go to the category.php or archive.php and change: to The overall aim was to have a hierarchal resource contained in the category page description. Whilst this is still a work in progress, you can see an example of what I am trying to achieve here: https://www.besthostnews.com/web-hosting-tutorials/cpanel/ https://www.besthostnews.com/web-hosting-tutorials/cpanel/mail/ If you have any further tips and advice as I continue to implement this (with good results so far), please feel free. Also, you can use the Visual Term Description Editor plugin to allow the wysiwyg editor for the category descriptions.
Intermediate & Advanced SEO | | TheWebMastercom1 -
Duplicate titles and descriptions problem?
We had an old site that used the urls for items site.com/32423432 we changed that to site.com/item name The old stuff has gone away and we have 301 redirects up. For some reason we are getting hit with duplicate titles on those pages and duplicate meta tags. The site relaunch was in November and we have a had a few problems but this just started showing up in the last week after having gone down. Any thoughts on a fix?
Intermediate & Advanced SEO | | EcommerceSite0 -
Google Listing & Description Categories Question
How do you set up a website or home page to get the individual listing below the description text. For example with the SEO moz listing there are many of the categories listed below the description. Such as SEO Blog, SEO tools ... Is there a way to add this to a home page so good will pick it up this way? I attached a screen shot of what I am talking about because I think I am likely using the wrong terminology. Npcpu.png
Intermediate & Advanced SEO | | fertilityhealth0 -
Do you think too many (nofollow) outbound links is a problem?
Just received my first crawl report from SEOmoz for my blog. I've rreceived a number of warnings / errors about having too many outbound links on my pages. These are simply comments from people (some pages have 300+) and the links are nofollowed. It seems like you guys must have a reason why this warning is in place, so I would love your theories...
Intermediate & Advanced SEO | | ViperChill0