I would like to know how do I redirect a domain and not just a URL. A client has purchased a domain (domain.com.tld) and wants that domain to point to domain.org.tld. Here is the thing, the customer does not have an actual website/hosting package with us, just a domain. I went into webmin and created a master zone for domain.com.tld but need to know how to forward it to domain.org.tld
Would you like it so that whenever they go to domain.com.tld, it redirects to domain.org.tld?
One way to do that would be to go into Server Configuration -> Website Redirects, and to create a redirect for the domain.
When I go to Server Configuration, there is no Website Redirects option but there is a Website Options link. Keep in mind that this client doesn’t have a virtual website server account so I can’t really go to Server Configuration simply because that option is attached to whatever hosting accounting I am currently viewing. All they have is just the domain that the purchased from us which we manage through the DNS Bind server within Webmin.
And yes, I want it so that whenever they go to domain.com.tld to redirect to domain.org.tld.
Hrm, I’m not sure if I fully understand the setup you have there.
However, they would need some sort of web hosting setup in order to do a redirect from one domain to another.
If that’s not an option on your server there, they’d need to setup the redirect to occur where the hosting is setup.
To put that another way – somewhere in the chain of servers, domain.org.tld needs to be setup with a web hosting package. It doesn’t need 50GB of space, but there does need to be a web server somewhere that claims to be able to accept requests for that domain.
Whatever server that is – you’d then configure it to redirect to the other domain.
You can configure that redirect using the Website Redirects screen (which is only available in recent Virtualmin versions), or you could use a .htaccess file with a mod_rewrite line that handles the redirect.
Ok, I took your advice and create a very small hosting account just to be able to do this. It is about 20MB in size. Now, I don’t see the option under Server Options in Virtualmin to do the redirect. The only option is “website options” and that area doesn’t have anything for redirects. I am running virtualmin 3.75.
Also, I do see a Frame Forwarding option. Is that where I should edit?
Yeah, your Virtualmin install is a bit older… the most recent version is 3.78, 3.75 is from November last year. A lot can happen in 6 months
So, I’d suggest upgrading in order to take advantage of all the new features that exist – that’d give you access to the Website Redirects option.
Barring that, you could either setup something using the Frame Forwarding you found, or setup a .htaccess file and use that to generate a redirect.
I got it updated and see the website redirect option. When I add the source url, I am entering domain.com and for the “URL at other website” I am entering domain.org. When I do that, I keep getting that my source is invalid. I even tried http://www.domain.com and http://domain.com and still gives me the same issue. What is the correct format?
I got it. I used “/” as a source URL per a post you responded to for someone else. I appreciate your help :-)…thanks a bunch
I’m glad you got it working, thanks for the update!
I cannot get this to work. I set up an alias of the top level domain i.e. mydomain.com and the alias is mydomain.co.uk so what I want is when the user enters mydomain.co.uk then mydomain.com shows in the address bar.