designsonline
Power Member
- Jan 22, 2009
- 651
- 146
Ive hunted through all the .htaccess sites and tutorials I can find and cant find one that will do this: (and ive tried modifying all the existing ones too and they wont do it!)
I want to combine the standard SEO rewrite to add missing www. etc..
With a rule that will also change any access to my domain (with or without the www.)
from http://www.domain.com
to http://www.domain.com#my_longtail_keyword
SO the end result im after is that if anyone visits my website at the domain level. they end up at http://www.domain.com#my_longtail_keyword
But I still want them to be able to visit pages within my site without being redirected, for example they could visit www.domain.com/mypage1.html and it will load, but if the visit www.domain.com they will be redirected via a 301 to http://www.domain.com#my_longtail_keyword
So if you are a .htaccess guru could you please post up the solution...?
Thanks
Is that clear enough? I just cant get it to work, ive been trying for 2 weeks, I need a hand.
I want to combine the standard SEO rewrite to add missing www. etc..
Options +FollowSymLinks
RewriteEngine on
RewriteCond %{HTTP_HOST} ^yoursite.com [NC]
RewriteRule ^(.*)$ http://www.yoursite.com/$1 [L,R=301]
With a rule that will also change any access to my domain (with or without the www.)
from http://www.domain.com
to http://www.domain.com#my_longtail_keyword
SO the end result im after is that if anyone visits my website at the domain level. they end up at http://www.domain.com#my_longtail_keyword
But I still want them to be able to visit pages within my site without being redirected, for example they could visit www.domain.com/mypage1.html and it will load, but if the visit www.domain.com they will be redirected via a 301 to http://www.domain.com#my_longtail_keyword
So if you are a .htaccess guru could you please post up the solution...?
Thanks
Is that clear enough? I just cant get it to work, ive been trying for 2 weeks, I need a hand.