Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
+5 votes
874 views
in Q2A Core by
edited by
Hello,

My Q2A website has got to path http://businessattitude.fr/question and http://www.businessattitude.fr/questions.
It's not good from an SEO point of view. Do you now how I can correct that?
It's really a general web developpement question, it's not because of Q2A but more because of my hosting service.
Is there anyone who know how I can correct that? Maybe using some HTAccess?

Thanks a lot.

2 Answers

+4 votes
by
by
Hi,

I already have the default htaccess which contains "DirectoryIndex index.php
RewriteEngine On
#RewriteBase /your-sub-directory
RewriteRule ^index.php/rewrite-test index.php/rewrite-pass [L]
RewriteCond %{REQUEST_URI} ^(.*)//(.*)$
RewriteRule . %1/%2 [R=301,L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^.*$ index.php?qa-rewrite=$0&%{QUERY_STRING} [L]
"

Can I add your code below this?

Thanks a lot
by
edited by
add below lines end of the code and check.

RewriteCond %{HTTP_HOST} !^(.*)\.domain-name\.com$ [NC]
RewriteRule ^(.*)$ http://www.domain-name.com/$1 [R=301,L]


Gideon: does it impact other lines of code in .htaccess?
0 votes
by
You do not need worry about this. However, you should add this domain to your account at http://www.google.com/webmasters/tools/ and choose which form Google should get and show in SERPs.
...