Home›Support›English Support›[Resolved] I want hosting advice on a multi-domain WPML installation (two TLD domains)
[Resolved] I want hosting advice on a multi-domain WPML installation (two TLD domains)
This thread is resolved. Here is a description of the problem and solution.
Problem:
The main domain is mydomain.be. The second domain is mydomain.com. My objective here is: when people are in Dutch, they see the .be site. When they're in English, they see the .com site.
Solution:
Set up both domains to point to the same server IP address and the same directory where WordPress is located. Alias configuration should all point to the same physical folder where your WordPress is being installed. URL should show the same website.
I want hosting advice on a multi-domain WPML installation (two TLD domains).
The main domain is mydomain.be. The second domain is mydomain.com. My objective here is: when people are in Dutch, they see the .be site. When they're in English, they see the .com site.
My site runs on a shared reseller environment of my own. I have cpanel access but cannot create addon domains. Is that a problem? In this tutorial (which I followed but I got stuck in the middle) there is no mention of the need of addon domains: https://wpml.org/tutorials/2016/04/use-wpml-different-domains-per-language/
Please help me with this so I can set up my .be and .com WPML installation...
Thanks
if you can not add Addon domains you can use Parked domains option as instructed in documentation.
Otherwise, if you are not using CPanel you will need to set up Manual DNS settings for domains.
You need to set up both domains to point to the same server IP address and the same directory where WordPress is located.
Whichever route you choose, the most important thing to consider is that the alias configuration should all point to the same physical folder where your WordPress is being installed. URL should show same website and WPML will take care of showing different languages for different domains.
I hope I was helpful. Don't hesitate to ask if you find any problem along the way, I'll gladly help you.
I have done everything according to the instructions.
Still, the redirect does not work properly.
I want to share my credentials but not here on the public forum.
Also I don't want to share my website url name. How can I do this privately?
In attachment the issue that I experience. But DNS is Okay and redirect also OK.
Also, hosting is perfectly OK. I contacted them and this was their answer:
"I have closely reviewed the guide and noticed that they suggest the configuration to be done via Parked domains. Whenever you park a domain name, its root directory is automatically set to be public_html. This said it would not be necessary to upgrade your hosting plan as on our StartUp hosting plan you can create Parked domains from your cPanel > Parked domains section."
As you can see, everything is set up like WPML suggests. Still no result. A bug? What should I do next?
I can see your URL in the debug information you shared, also any links and images shared are only visible to us.
We are not allowed to access your hosting account for security reasons, I can access your WP admin dashboard but the problem is not there. WPML configuration is correct but not working since domains are not set up.
That being said, you will need to set up your domains DNS as instructed, manually or via parked/addon domains.
I see your hosting said you are allowed to add Parked domains, so you can easily just add .com domain as parked domain ( cPanel > Parked domains section.)
You can see in the images I shared your domains currently have different DNS configurations.
Please let me know how it goes and don't hesitate to ask if you find any problem along the way.
Are the screenshots you attached private ones? They contain private information.
I have both domains in the correct DNS regarding the A records. The other records wouldn't matter, I'd assume?
In any case, it does work now. The translation is active on the .com site.
My finding is that the "validate when saving" checkbox is the cause of the bug. When I uncheck it, all settings save correctly, and the domain switch functions as expected. When I check the checkbox, and I save, I get the error: "Not valid". What does WPML mean with "not valid"? What is "not valid"? In any case, it seems valid though, as front-end everything runs well...
That function "Not valid" can sometimes give a false positive error, it could be that WPML can not test the domains correctly due to server configuration or domain configuration.
In your case, I think this issue happens since you are telling WPML to check the HTTPS version of .com site, and you don't have HTTPS active on .com domain and thus WPML can not reach and test that address.
You can also see that if you switch to the English language on the frontend it goes to HTTP version. I would advise for security and SEO reasons to implement HTTPS to .com domain, too.
Let me know if there is anything else I can help you out with, I will be glad to do so.
Regards,
Drazen
This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.