Joomla community powered logo

Site Slogan

Server configuration parameters

The assumption worth mentioning before we start is that I suppose your site is running on an Apache webserver. I suppose the same kind of settings will exist for IIS, but as I don't have any site running on that system, I wasn't able to test it so I won't be able to give any hint on what works best.

Keep sessions alive

First of all, you need to make sure your sessions are kept alive. If you are on shared hosting you can only apply this setting if your provider hasn't done it on the general level. But it's always worth trying.

Adapt the .htaccess file in the root directory of your site with the following extra lines of code:

# ----------------------------------------------------------------------
# Keep connection alive
# ----------------------------------------------------------------------
Header set Connection keep-alive

Enable communication compression

A lot of communication is necessary between your server and your customer before they have all the info you will provide. You can send this info just the way it has to be shown on the customer side, but if you compress the communication then you can have a lot less traffic to be exchanged between the server and the client so for the same information you need less time and bandwidth. In order to be able to exchange the information like this, you have to enable compression on your server for the traffic. As we are working with Joomla, we will for sure need the .php file extension to be compressed, but also all supporting files (like css, js, and maybe even html pages) have to be included. 

An important parameter for the Google PageSpeed ranking is that you have to be able to serve both old and new browsers. The old ones don't support compression, while the new ones do. And Google wants you to speed up your pages to serve your content to your customers as fast as possible. In order to be able to serve both kinds of browsers at the same time, you have to use the 'Vary Accept-Encoding' parameter, which you have to put at the same place as where you keep your sessions alive.

In order to enable compression and to respect the problems older browsers can have with compression, you have to add these lines to the .htaccess file

# ----------------------------------------------------------------------
# Enable compression but make sure you can server older browsers too
# by accepting that for these browsers, there won't be any compression
# as they can't handle it
# ----------------------------------------------------------------------
<FilesMatch "\.(js|css|html|htm|php|xml)$">
Header append Vary Accept-Encoding
SetOutputFilter DEFLATE
</FilesMatch>

A final remark: these settings (Header append Vary Accept-Encoding) have to be after a setting which has initiated the Header, otherwise you have to use the 'Header set'. As my first setting is always the keep-alive setting, this isn't any problem in my set up but your preferences may be different.

Cache Control

If specific parts of your page don't change a lot (in most of the cases we will speak about images and movies), you can safely indicate they won't change for some time and so your customer will use the browser cache when accessing your page for a second, third, ... time. This will give a better user experience (faster response time because it will be taken out of the cache of the user's browser) and less bandwidth need for you because the user won't download it again.
The lines you have to add to your .htaccess file are

<FilesMatch "\.(ico|pdf|flv|jpg|jpeg|png|gif|js|css|swf)$">
ExpiresActive On
ExpiresDefault "access plus 1 years"
Header append Cache-Control "public"
</FilesMatch>

This way, the default expiration for all kinds of files is from the moment of access by your customer plus 1 year. The Cache-Control "public" means that all proxies between your site server and the customer's browser will also try to keep this part of your page in their cache during 1 year, so they too don't have to go back to your site server when they will have to serve the content to a client asking for it.

NOTE! This site uses cookies.

If you do not change browser settings, you agree to it. Learn more

I understand

Cookies

To make this site work properly, we sometimes place small data files called cookies on your device. Most big websites do this too.

What are cookies?

A cookie is a small text file that a website saves on your computer or mobile device when you visit the site. It enables the website to remember your actions and preferences (such as login, language, font size and other display preferences) over a period of time, so you don’t have to keep re-entering them whenever you come back to the site or browse from one page to another.

How do we use cookies?

A number of our pages use cookies to remember:

Also, some videos embedded in our pages use a cookie to anonymously gather statistics on how you got there and what videos you visited.

Enabling these cookies is not strictly necessary for the website to work but it will provide you with a better browsing experience. You can delete or block these cookies, but if you do that some features of this site may not work as intended.

The cookie-related information is not used to identify you personally and the pattern data is fully under our control. These cookies are not used for any purpose other than those described here.

How to control cookies

You can control and/or delete cookies as you wish – for details, see aboutcookies.org. You can delete all cookies that are already on your computer and you can set most browsers to prevent them from being placed. If you do this, however, you may have to manually adjust some preferences every time you visit a site and some services and functionalities may not work.

You can find the full EU privacy guideline by clicking on this link