General informations about JotCache extension

TOPIC: domain url issue

domain url issue 06 Mar 2015 14:05 #1279

Hello Jotcache,

I have a problem with how the internal links of a website are formed while using the JRoute class.
I am posting my question here as the server administrator told me that there maybe a conflict between the server cache and Jotcache.

Some of the internal urls of the site though do not work properly or should I say do not form properly.
Instead of them being in the following format:
www.mydomain.gr/[the rest of the url]

they are formed like this:
www.anotherdomain.gr/[the rest of the url]

where the ‘anotherdomain.gr’ is another website in the shared server.

I contacted the server administrator and he is puzzled as I am.
He says that the problem occurs because there is a conflict between the server cache and the eshop cache that I have implemented (Joomla cache and Jotcache).

We tried to overcome the problem by placing the ‘mydomain.gr’ in the $live_site of the configuration file:
$live_site = ‘www.mydomain.gr

The problem is still there though.
So why it doesn’t take into account the $live_site variable and it places another domain when I specifically added my domain to $live_site?

The links are formed using the JRoute class.

Is there another way, except $live_site, to clearly and explicitly force the system to use only the domain ‘www.mydomain.gr’, so it doesn’t have to look for it when it forms the links?

Thank you very much in advance


Joomla version : 2.5
JotCache version : 4.2
site template:
system plugins :
The administrator has disabled public write access.

Re: domain url issue 06 Mar 2015 14:16 #1280

Setting of $live_site is not solution. Try to use multisite option of JotCache (here are stored full URLs not only URI).
The administrator has disabled public write access.

Re: domain url issue 06 Mar 2015 15:02 #1281

Hello JotComponents

Thank you very much for your quick reply.

I just did what you have suggested but unfortunately the problem persists.

Let me try to give some more details that may help.
Before placing my domain in the $live_site ($live_site = ‘www.mydomain.gr’) the problem occurred randomly on both the menu item links that Joomla creates and the links that I have created using the JRoute class.

The last 10 days that I have placed the $live_site variable, and now that I did what you have suggested, the problem occurs only for specific links (as far as I can tell) that I have created using the JRoute class. Here is an example of the code that I am using for the links:
<?php echo JRoute::_('index.php?option=com_mijoshop&route=product/category&path=1&Itemid=128&filter_newreleases=1', true, 1); ?>

The above code is written in an override file of the default.php file of the mod_menu.

Any thoughts?

Thank you very much for your help.

Joomla version : 2.5
JotCache version : 4.2
site template:
system plugins :
The administrator has disabled public write access.

Re: domain url issue 06 Mar 2015 17:15 #1283

I have another hint that may help.

I have disabled Joomla cache and kept only Jotcache.
As I test the website so far, the problem hasn’t occurred on the website in general and in the specific links that I mentioned before.

Do you think that there is a conflict between Joomla cache (Conservative caching) and Jotcache causing the specific problem?

Thank you very much for your help.

Joomla version : 2.5
JotCache version : 4.2
site template:
system plugins :
The administrator has disabled public write access.

Re: domain url issue 23 Mar 2015 10:01 #1323

Hello JotComponents,

I’m writting because the issue I have described in a previous post still exists.

Because of that I was forced to disable Jotcache in order to see what is happening.

Could you please inform me of the following?
Jotcache, does it ignore the $live_site parameter?
Also, is there a way to tell Jotcache to use a specific domain in all internal links?

Thank you very much in advance

Joomla version : 2.5
JotCache version : 4.2
site template:
system plugins :
The administrator has disabled public write access.

Re: domain url issue 23 Mar 2015 10:19 #1324

JotCache is not ignoring '$live_site parameter' because is not direct using this parameter.

Make a check :
Disable JotCache plugin and call from browser :
https://www.anotherdomain.gr/
If Joomla page appears with www.anotherdomain.gr/ shown in browser page link then your server responses to different domains. Then you need to set .htaccess file for redirect from wrong domain to your target domain :
https://www.mydomain.gr
The administrator has disabled public write access.

Re: domain url issue 21 Feb 2016 09:49 #1620

This is not a solution, because it is not known what the next domain.
Tired each time to remove the cache.
Please, help. This is a very big problem.
Only today it was five substitutions of all links of the main page from the IP 115.61.84.113. This IP I blocked, but there are other IPs.
Here is an excerpt from the access.log:
115.61.84.113 - - [21/Feb/2016:03:57:47 +0300] "GET / HTTP/1.0" 200 59568 "eos.changyou.com/" "Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0)"
115.61.84.113 - - [21/Feb/2016:08:09:06 +0300] "GET / HTTP/1.0" 200 59662 "book.sohu.com/" "Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0)"
115.61.84.113 - - [21/Feb/2016:08:09:11 +0300] "GET / HTTP/1.0" 200 59650 "www.sina.com.cn/" "Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0)"
115.61.84.113 - - [21/Feb/2016:10:34:22 +0300] "GET / HTTP/1.0" 200 59348 "www.elong.com/" "Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0)"
115.61.84.113 - - [21/Feb/2016:10:42:39 +0300] "GET / HTTP/1.0" 200 59343 "3gqq.qq.com/" "Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0)"

Joomla version: 3.4.8
JotCache version: 5.2.1
Thank you in advance.
The administrator has disabled public write access.

Re: domain url issue 21 Feb 2016 10:11 #1621

UPDATED !
Try to include into .htaccess file in Joomla root following commands :
RewriteCond %{SERVER_PORT} ^443$ [OR]
RewriteCond %{HTTPS} =on
RewriteRule ^(.*)$ http://www.yourdomain.com/$1 [R=301,L]
RewriteCond %{HTTP_HOST} !^www\.yourdomain\.com [NC]
RewriteRule ^(.*)$ http://www.yourdomain.com/$1 [R=301,L]
RewriteCond %{REQUEST_URI} !^/index\.php
RewriteCond %{QUERY_STRING} ^format=raw$
RewriteRule ^(.*)$  index.php/$1 [L]
First part of commands redirects all external requests with HTTPS protocol to HTTP protocol and second part rewrites any domain not matching exactly www.yourdomain.com to www.yourdomain.com.
NOTE : But here is still not clear why your server responds to 'foreign' domains.
The administrator has disabled public write access.

Re: domain url issue 22 Feb 2016 16:39 #1622

Thanks for the quick response.
The first and second I already use.

What is the third rule?:
RewriteCond %{REQUEST_URI} !^/index\.php
RewriteCond %{QUERY_STRING} ^format=raw$
RewriteRule ^(.*)$ index.php/$1 [L]

Thank you in advance.
The administrator has disabled public write access.
Time to create page: 0.296 seconds
We have 84 guests and no members online
Copyright © 2015 JotComponents
We have 84 guests and no members online
Copyright © 2017 JotComponents