Hot answers tagged

17

It's not a DNS setting; you need to set up a redirect from mydomain.com to www.mydomain.com. Fortunately, Godaddy provides this service for free; follow the directions at http://community.godaddy.com/help/article/422


12

You could make example.com/test.com resolve to the same webserver (IP) via dns (CNAME if you like) and that would work. If you are looking to do this on a per-path basis than no. DNS is ignorant of things like URL. DNS is simply translating the host part of the url (example.com) into IP address. The web server is in charge of figuring out what (or where) ...


8

As has been noted, this can not be done entirely with DNS. However, if you have the DNS for example.com refer to the same server as test.com it is very simple to configure Apache to accomplish what you wish to do. Just add the following: <VirtualHost *:80> ServerName example.com Redirect permanent / http://test.com/ </VirtualHost> This ...


6

Masked forwarding uses frames to display the site being redirected to. For dropbox that does not appear to work. You may want to use use a regular redirect instead. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html> <head> <title>dropbox.tombrito.com</title> </head> ...


3

Here is the exact .htaccess rule that I use to redirect all requests from www.mydomain.com to mydomain.com (since the shorter is my canonical URL): RewriteCond %{HTTP_HOST} ^www\.mydomain\.com$ [NC] RewriteRule ^(.*)$ http://mydomain.com/$1 [R=301,L] That's easy enough to modify to redirect from foo.com to foobar.com, while preserving the request, the ...


3

You cannot do this via DNS alone. 301 redirects are not a DNS thing. They're a webserver thing. What you can do is point your example.com DNS entries to the same server as test.com, and set up example.com as an alias domain to test.com.


3

You can analyze the $_SERVER['HTTP_HOST'] variable in PHP: if( $_SERVER['HTTP_HOST'] !== 'abc.example.com' ){ header('Location: http://abc.example.com/', true, 301); exit; } If it's not abc.example.com it will redirect to it. I guess you can put it into your index.php at the very top.


3

It would be much better to configure the webserver to handle this redirection. It is fairly trivial to configure Apache to do something along these lines. If you are using Apache, look up RewriteRule. Most other web servers have comparable features.


3

This is just another case of two or more URLs pulling up the same content. You have two ways you can handle this: Do a 301 redirect from the URLs you do not want to show in the search results to the one that you do want to show. Use canonical URLs <link rel="canonical" href="http://www.12345.com/example.html" />


3

Generally you should do HTTP-level redirects from the alternate host names to the canonical name of your choosing. This makes the entry in the browser location bar switch to the correct name and will act as a cue to search engines to phase out the alternates. The response code should be 301 "Permanent" in this case. Don't forget this is done on a host name ...


2

Forward only -- Use 301 redirects to redirect from myDomain.com to myApp.appspot.com Forward with Masking -- Use frames to keep the URL as myDomain.com while instructing the browser to fetch the content from myApp.appspot.com. The URL then doesn't change as you navigate the site. Forwarding (of any type) is not what you want. You actually want your ...


2

Personally I would have the content hosted on .co.uk and a redirect from .com to the content on .co.uk, that way any links will gain SEO momentum for the .co.uk domain.


2

This is a DNS record issue. Make sure that you have a DNS A record called domain.com, and that it's pointing at your server. A lot of the time, people only have the www.domain.com. A record believing you have to put www. before all domain names. However, people like myself never bother typing www., so we end up putting "domain.com".


2

In Chrome's Inspector you get this error Refused to display document because display forbidden by X-Frame-Options. Two ways that should fix it: IFRAMES - Custom Domain Dropbox Add some PHP - Overcoming “Display forbidden by X-Frame-Options” <?php header('X-Frame-Options: GOFORIT'); ?>


2

Do you actually have a * wildcard record in your DNS zone file? If yes then all you need to do is add an A record into the zone file and point it to the IP hosting your domain.ca now all connections to that specific sub domain will go to www.domain.com while the other wildcard subdomains will go some place else. Or in cPanel you would simply create your ...


2

Using 301 permanent redirects from one domain to the other is your better option. In fact, "domain parking" won't achieve what you want at all. Parking a domain generally means that the registrar will put up its own page there. That page will generally say "coming soon" and have advertisements for the registrar's services.


2

Reference http://lifesforlearning.com/heroku-with-godaddy/ In the FORWARD AND MASKING section (which is under SETTINGS >> Forwarding), I was forward(ing) with masking (as you can see in the screenshot in the question above) to the herokuapp >> http://appsparkler.herokuapp.com. I changed that to forward(without masking) to http://www.appsparkler.com as you ...


2

If you are redirecting, or forwarding, then the chocolate-treat.com won't ever get into Google. You'll only see chocolate-dessert in there. So you can't really accomplish what you're trying to do. The better way is to create new websites on chocolate-treat.com and chocolate-snack.com and produce some great content on those domains. Great content always wins ...


2

If new-domain.com is literally a new domain you have just registered then no type of forwarding/redirection will provide any kind of SEO benefit for old-domain.com. However, if new-domain.com has been hosting an established website for a period of time and has itself been indexed for its own merits and acquired a number of backlinks, then setting up a 301 ...


1

The issue with those types of forwards is they are often merely iframes, which are abysmal for SEO. What you should ensure is that it is a 301 Permanent Redirect. If not, use the following code in the .htaccess on the root of your site to accomplish the same effect. RewriteEngine on RewriteRule (.*) http://www.new-domain.com/$1 [R=301,L]


1

The way that I do is, add the two domains to cloudflare, redicted it normally to the hosting. On the hosting cpanel, add both domains, and set on cpanel that this site redirect permanent to your main site, so if any day has to change something, is only on the web provider end.


1

I don't think you can do that with page rules, or at least not on the free plan. You can use a htaccess/vhost server side rule though (you may or may not need to include RewriteEngine On depending on if it's on already in htaccess) RewriteEngine On RewriteCond %{HTTP_HOST} ^(www\.)?example\.uy$ [NC] RewriteRule ^(.*)$ "https://www\.example\.com\.uy/$1" ...


1

Find something like "Web Address Mapping" in the available options inside your admin panel. There, it should give you an option to redirect to redirect domain A (current) to domain B (interested or target domain/url/uri). I'm not expecting it to be difficult. It might have a different name but it should give a similar result.


1

The best way to go about it is to transfer the files in the group folder at mysite.com to the document root folder at mysitegroup.org and make one of the HTML producing files by the name starting with index so that its executed. For example, make sure one file is index.htm or index.html or if you're using something like wordpress or another content ...


1

Instead of selecting forward with mask you need to select forwarding only. Putting it inside a frame is how they mask the domain the site is on.


1

What you could do is make example.com and www.example.com as separate URLs pointing to two different folders on the server, but make www.example.com point to the folder with the website contents. Then these lines can be added to apache's main configuration file (httpd.conf) if you have mod_rewrite installed. RewriteEngine On RewriteCond %{HTTP_HOST} ...


1

You have implemented this redirect with Namecheap. Their help document explains how to set up the redirects either way: www1 http://destination.com Permanent (301) www2 http://destination.com/ Permanent (301) In the above case, www1.yourdomain.com will not pass values to the destination URL so, www1.yourdomain.com/xyz.html will redirect ...


1

Turns out that from the DNS settings you need to create a new host record.


1

Short answer: No, it's not possible to setup wildcard subdomains with .htaccess. To achieve what you want to do, you need to have a wildcard record in your DNS zone file, because your nameserver is where the subdomains are looked up. Also, many hosting companies will not allow you to add a wildcard record, so you'll have to check with them.


1

Why is .www deprecated? In order to answer this question, we must first recall the definition of WWW: World Wide Web: n. Abbr. WWW 1) The complete set of documents residing on all Internet servers that use the HTTP protocol, accessible to users via a simple point-and-click system. 2) n : a collection of internet sites that ...



Only top voted, non community-wiki answers of a minimum length are eligible