Browsing articles tagged with " Joomla"

Simple PHP script to migrate articles from Radiant (Rails CMS) to Joomla (PHP CMS)

I was working on migrating data from Radient 0.8.1 (Ruby on Rails CMS) to Joomla 2.5.6 (PHP CMS), and it was a bit silly but interesting task. So, I wrote the following simple php script to migrate articles, but you should adjust some variables first.
Continue reading »

Preventing Joomla! from sending no-cache in headers

If you are using Joomla! 1.5+ and trying to cache with nginx or other caching server and at same time you don’t want to use Joomla! system cache plugin. You’ll face a big problem, that Joomla! is sending “Cache-Control: no-cache” and “Pragma: no-cache” in response headers.

Here’s the solution :

1. Edit the following file :

Joomla root/libraries/joomla/environment/response.php

2. Search for the following code :

if (self::allowCache() === false) {
self::setHeader('Cache-Control', 'no-cache', false);
// HTTP 1.0
self::setHeader('Pragma', 'no-cache');
}

3. Comment this if condition, to be as follows

/*
if (self::allowCache() === false) {
self::setHeader('Cache-Control', 'no-cache', false);
// HTTP 1.0
self::setHeader('Pragma', 'no-cache');
}
*/

Now, you can disable Joomla! caching, and run whatever caching server, as nginx.