I have two websites, for simplicity I will call them: old.com new.com old.com I have pretty much given up on. After sitting for a couple years, It gets about 400 hits a month and falls a little short of the hosting fees. It has a few javascript games on it. new.com is my shiny new toy. I am messing with it every day and have a couple other people working diligently on it too. I think it has potential, but it needs some traffic to get started. old_domain_name ---> newSite.com/gamePage.html Code (markup): I want to salvage the traffic from old.com and just make a page on my new site that holds the games from the old site. How do I point the oldDomain to a single page on the new site? If this is possible, Is it also possible to keep the old established domain name (with relevent game-related keyword) so that people and search engines see that domain name when they are on the game pages of my new site? Domains and hosting accounts are all at GoDaddy. Thanks in advance for any tips and suggestions.
This depends on the service you are using. The registrar (the site service that registered the domain) will have a control panel that allows you to to set the DNS records and point hostnames to different servers/IP's The exact instructions vary by registrar. You could set your record to point to new.com www.hostcat.com
Create an .htaccess file in the root directory of your old domain and add the following code: redirect 301 / http://www.newdomain.com/GamePage.html Code (markup): This will redirect all pages from old domain to GamePage.html of new domain
Pick Any ! [B][U]PHP Redirect[/U][/B] <? Header( "HTTP/1.1 301 Moved Permanently" ); Header( "Location: http://www.new-url.com" ); ?> [B][U]ASP Redirect[/U][/B] <%@ Language=VBScript %> <% Response.Status="301 Moved Permanently" Response.AddHeader "Location","http://www.new-url.com/" %> [B][U]ASP .NET Redirect[/U][/B] <script runat="server"> private void Page_Load(object sender, System.EventArgs e) { Response.Status = "301 Moved Permanently"; Response.AddHeader("Location","http://www.new-url.com"); } </script> [B][U]JSP (Java) Redirect[/U][/B] <% response.setStatus(301); response.setHeader( "Location", "http://www.new-url.com/" ); response.setHeader( "Connection", "close" ); %> [B][U]CGI PERL Redirect[/U][/B] $q = new CGI; print $q->redirect("http://www.new-url.com/"); [B][U]Ruby on Rails Redirect[/U][/B] def old_action headers["Status"] = "301 Moved Permanently" redirect_to "http://www.new-url.com/" end [B][U]Redirect Old domain to New domain (htaccess redirect)[/U][/B] Create a .htaccess file with the below code, it will ensure that all your directories and pages of your old domain will get correctly redirected to your new domain. The .htaccess file needs to be placed in the root directory of your old website (i.e the same directory where your index file is placed) Options +FollowSymLinks RewriteEngine on RewriteRule (.*) http://www.newdomain.com/$1 [R=301,L] Please REPLACE www.newdomain.com in the above code with your actual domain name. In addition to the redirect I would suggest that you contact every backlinking site to modify their backlink to point to your new website. Note* This .htaccess method of redirection works ONLY on Linux servers having the Apache Mod-Rewrite moduled enabled. [B][U]Redirect to www (htaccess redirect)[/U][/B] Create a .htaccess file with the below code, it will ensure that all requests coming in to domain.com will get redirected to www.domain.com The .htaccess file needs to be placed in the root directory of your old website (i.e the same directory where your index file is placed) Options +FollowSymlinks RewriteEngine on rewritecond %{http_host} ^domain.com [nc] rewriterule ^(.*)$ http://www.domain.com/$1 [r=301,nc] Please REPLACE domain.com and www.newdomain.com with your actual domain name. Note* This .htaccess method of redirection works ONLY on Linux servers having the Apache Mod-Rewrite moduled enabled. Code (markup):
Oh i read it.I know you can atleast use php to achieve it out of all.Now if you expect everyone to write EXACT code for RogerDodgr then i wonder how he'll learn.
Thanks Panwell-VW. Even if it was copy/pasted, it provided one detailed option for me, and so I appreciate. But, all of those options assume I keep the old hosting account; I would prefer to close the hosting account at oldDomain.com . Whatever actions I take will need to be done at the new hosting server.
If you are using cPanel or DirectAdmin you even do not need to modify any .htaccess file just go to Site Redirection section and point 301 (permamnent). That is it!
Create. Htaccess file in the root directory of your old domain and add the following code: This will redirect all pages from the old domain GamePage.html new domain If I have any good idea I will post, thx very much Code (markup):