Multiple Joomla sites on same host, URLs are getting mixed!

Need help with the Administration of your Joomla! 3.x site? This is the spot for you.

Moderator: General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10.
Locked
vincebodie
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 138
Joined: Thu Sep 02, 2010 3:57 am

Multiple Joomla sites on same host, URLs are getting mixed!

Post by vincebodie » Sat Apr 30, 2016 3:36 pm

I have several Joomla sites on the same hosting platform (Linux/cPanel VPS), and I am using EasyFrontendSEO component on one of them (http://extensions.joomla.org/extension/ ... ontend-seo). I just noticed that the component is showing URLs that contain strings from another one of my sites!

For example:

Code: Select all

http://site1.com/site1.html <-- this is OK
http://site1.com/site2.html <-- this URL points to content on a different site!
The two sites do not share any parameters such as a shared database. The only thing they have in common is being on the same hosting plan.

I will be heading over to the EasyFrontendSEO site to see if there is any info there that points to the component being at fault.

In the meantime, if anyone here has any insights I would greatly appreciate it!

itoctopus
Joomla! Virtuoso
Joomla! Virtuoso
Posts: 4025
Joined: Mon Nov 25, 2013 4:35 pm
Location: Montreal, Canada
Contact:

Re: Multiple Joomla sites on same host, URLs are getting mix

Post by itoctopus » Sun May 01, 2016 4:49 am

Are you sure you don't have any rules in your .htaccess file causing this problem? Try reverting back to a default .htaccess file and see if the problem persists.
http://www.itoctopus.com - Joomla consulting at its finest
https://twitter.com/itoctopus - Follow us on Twitter

User avatar
Per Yngve Berg
Joomla! Master
Joomla! Master
Posts: 30926
Joined: Mon Oct 27, 2008 9:27 pm
Location: Romerike, Norway

Re: Multiple Joomla sites on same host, URLs are getting mix

Post by Per Yngve Berg » Sun May 01, 2016 1:34 pm

You have to put the two Joomla instances into different folders or use sub-domains.

Code: Select all

http://site1.com/site1/index.php
http://site1.com/site2/index.php

vincebodie
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 138
Joined: Thu Sep 02, 2010 3:57 am

Re: Multiple Joomla sites on same host, URLs are getting mix

Post by vincebodie » Sun May 01, 2016 4:21 pm

itoctopus wrote:Are you sure you don't have any rules in your .htaccess file causing this problem? Try reverting back to a default .htaccess file and see if the problem persists.
It's possible this was the issue. Both of these sites got moved from the same host (InMotion) to another host (Arvixe), and then several months later back to InMotion (stay away from Arvixe!). During these moves I had to tweak .htaccess files, and I may have used improper naming conventions for the backed up files (such as '.htaccess-OLD'). There are rewrite rules in the files on both sites for resolving raw IP addresses, so this is a possible clue:

Code: Select all

RewriteCond %{HTTP_HOST} ^999\.888\.777\.666
RewriteRule (.*) http://site1.com/$1 [R=301,L]
I have now renamed the backup files without the beginning dot, and I will check the EasyFrontendSEO component to see the results.
Last edited by vincebodie on Sun May 01, 2016 4:25 pm, edited 1 time in total.

vincebodie
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 138
Joined: Thu Sep 02, 2010 3:57 am

Re: Multiple Joomla sites on same host, URLs are getting mix

Post by vincebodie » Sun May 01, 2016 4:22 pm

Per Yngve Berg wrote:You have to put the two Joomla instances into different folders or use sub-domains.

Code: Select all

http://site1.com/site1/index.php
http://site1.com/site2/index.php
Thanks for the suggestion. Both sites are on their own cPanel, so doubtful this is the issue.

User avatar
Per Yngve Berg
Joomla! Master
Joomla! Master
Posts: 30926
Joined: Mon Oct 27, 2008 9:27 pm
Location: Romerike, Norway

Re: Multiple Joomla sites on same host, URLs are getting mix

Post by Per Yngve Berg » Sun May 01, 2016 4:23 pm

You have site1.com in both urls. Is that a typo?

vincebodie
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 138
Joined: Thu Sep 02, 2010 3:57 am

Re: Multiple Joomla sites on same host, URLs are getting mix

Post by vincebodie » Sun May 01, 2016 4:30 pm

Per Yngve Berg wrote:You have site1.com in both urls. Is that a typo?
No, what I'm pointing out is that the article linked in the first URL belongs to the root site, while the second URL contains an article from site2:

Code: Select all

http://site1.com/site1.html <-- this content belongs to site1
http://site1.com/site2.html <-- this content belongs to site2

User avatar
Per Yngve Berg
Joomla! Master
Joomla! Master
Posts: 30926
Joined: Mon Oct 27, 2008 9:27 pm
Location: Romerike, Norway

Re: Multiple Joomla sites on same host, URLs are getting mix

Post by Per Yngve Berg » Sun May 01, 2016 4:58 pm

This is a fault in the Virtual Domain Setup on the server. Joomla uses the Php system Variable $SERVER to find the url to the live site. The server is supplying the same value for both sites.

vincebodie
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 138
Joined: Thu Sep 02, 2010 3:57 am

Re: Multiple Joomla sites on same host, URLs are getting mix

Post by vincebodie » Mon May 02, 2016 4:23 pm

Per Yngve Berg wrote:This is a fault in the Virtual Domain Setup on the server. Joomla uses the Php system Variable $SERVER to find the url to the live site. The server is supplying the same value for both sites.
OK, that sounds like the kind of answer I am looking for. I will get with InMotion and post back here with the results.
Thanks!

vincebodie
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 138
Joined: Thu Sep 02, 2010 3:57 am

Re: Multiple Joomla sites on same host, URLs are getting mix

Post by vincebodie » Thu May 05, 2016 6:08 pm

Per Yngve Berg wrote:This is a fault in the Virtual Domain Setup on the server. Joomla uses the Php system Variable $SERVER to find the url to the live site. The server is supplying the same value for both sites.
I posted a query with my hosts InMotion Hosting, and this was their reply:
"It appears that what ever the module you have for SEO is doing it is looking to any page that it can find on the server despite being on a separate IP address or user. I do apologize however this lies in the coding of the module and there is nothing that we can do in regards to this, I would advise getting a work around from the module provider or seeking out a different SEO module that did not interact with your websites in this manner."
This leads me to ask how any Joomla component could access a completely different account on the server with a different cPanel and IP address. So strange.


Locked

Return to “Administration Joomla! 3.x”