I’ve tried everything from .htacess redirect 301 to other tricks but nothing works.
I have about 30 odd links which Google webmaster tools keep giving a 404 error warnings on and I need to redirect them back to the home page.
xxxhttp://www.mydomain.com/games-forum/viewforum.php?f=7&mark=topics&sid=d3f326d165a46e91547913ae3baaf2ca
Can some please show me how I can get the above plus similar links to do a permanent 301 to the home page please?
Cheers
Dave
ErrorDocument 404 http://gamingonlinefree.com/
(in fact, I have lots of sites and send all 404’s to one favorite)
RewriteRule (.*) [url]http://www.site.com/[/url] [R=301,L]
try this one…
if it doesnt work ill play on my server till i get it
RewriteEngine on
RewriteCond %{REQUEST_URI} ^/games-forum/
RewriteRule (.*) http://www.mydomain.net.au [R=301,L]
[/CODE]
think I’ll go chase this up on a forum which specifically deals with this stuff. Thanks for your help [COLOR=#0000ff]allfreechips[/COLOR] and everyone else too
Cheers
Dave[CODE]
RewriteEngine on
RewriteCond %{REQUEST_URI} ^/games-forum/
RewriteRule (.*) http://www.mydomain.net.au [R=301,L]
[/CODE]
think I’ll go chase this up on a forum which specifically deals with this stuff. Thanks for your help allfreechips and everyone else too ” title=”” class=”bbcode_smiley” />
Cheers
Dave
I gave up trying to do this with htaccess. I contacted my server management guys and was given the following small piece of php code which I added to the first line of my header (WP).
[PHP]
if($_GET != “” || $_GET!= “” ){
header(“Location:http://www.mydomain.com”);
}
[/PHP]
It checks for any file call which contains “p” then variables (in my case the old phpbb session ID) and serves the home page, You could do this for any url if needed.
Cheers
Dave
Please login or Register to submit your answer