Hi Folks, This time I need help for my website http://techbongo.com as I've got lot of unnecessary old links picked up by search engines. I had my old site on http://techbongo.com/home/ where Joomla was installed. Now my new site is located on http://techbongo.com/ I want to redirect each and every files/folders under 'home' sub-folder to http://techbongo.com/ I don't want to add the query strings of home folders to the root folder. I mean, I just need a permanent wildcard redirect of 'home' sub folder to the root folder and don't want to append anything else to the root folder while redirecting . I know, some brilliant Apache experts are here. Please help he with the .htaccess code. I'm facing great trouble in SEO as all the 30 files of my total listed 54 files are not existing now. That's I need this help. By the way, will it affect my ranking anyhow?
Options +FollowSymlinks RewriteEngine on rewritecond %{http_host} ^techbongo.com/home [nc] rewriterule ^(.*)$ http://www.techbongo.com/$1 [r=301,nc] put that code in .htaccess of ur home directory
I don't want to redirect a url, say hxxp://techbongo.com/home/content/index.php?itemid=5 to hxxp://techbongo.com/content/index.php?itemid=5, rather I'll like it redirected to http://techbongo.com/ itself. I don't know, if this piece of code will work or not. Will it work? I guess, you got my point. I want a wilcard redircted to my site root without appending any querystring/sub-path to it.
Originally Posted by Bohra View Post Options +FollowSymlinks RewriteEngine on rewritecond %{http_host} ^techbongo.com/home [nc] rewriterule ^$ http://www.techbongo.com/ [r=301,nc] Now it will redirect to the main thing always
Well you can use the following method as well... Make an "index.php" with the following code and upload it to your main domain. <? Header( "HTTP/1.1 301 Moved Permanently" ); Header( "Location: http://www.techbongo.com/home" ); ?>