Add Custom Javascript

Load your custom Javascript code in the head of your Joomla website.
Available as plugin and module for Joomla 2.5.x and 3.x.

Joomla 2.5.x Compatible Joomla 3.x Compatible

Which to use, the plugin or the module?

In general you should use the plugin if you want your custom Javascript code to be loaded to all pages of your website and you should use module if you want to load the cutom Javascript code in specific pages.

But have in mind that plugins are loaded after the modules. This means that the plugin version of Add Custom Javascript will be loaded after the module version.

Caution:

If you use the plugin you have to place it at the end of the plugin order in the Plug-in Manager.

If you use the module you have to place it in the module position that loads last among the other module positions. Also place it at the end of the module order in the Module Manager.

Joomla Installation

Notice: Don't forget to unzip the downloaded file. In there you will find one plugin and one module, both working for Joomla 2.5.x & 3.x.

  1. Download Add Custom Javascript and unzip it.
  2. In the Joomla control panel select: Extensions > Install/Uninstall.
  3. In the Upload Package File section click Choose File and locate the "addcustomjavascript.zip" file if you want to use the plugin or "mod_add_custom_javascript.zip" if you want to use the module.
  4. Then click Upload & Install to upload the file and complete the installation.

Configuration

In order to configure Add Custom Javascript go to the Joomla control panel and select: Extensions > Plugin Manager for the plugin version or Extensions > Module Manager for the module version. Locate "System - Add Custom Javascript" in the list and click it. You can see the Parameters of the extension as below:

Joomla Parameters

Parameters

The Add Custom Javascript extension has the following parameters:

Change Log

Notice

Please have in mind that some templates and extensions may have special code customizations that affect the normal operation of Joomla and this may not allow your custom Javascript code to load last.

Full Customization

If you need full customization of your website then you can use all the following free extensions:

  1. Add Custom PHP
  2. Add Custom CSS
  3. Add Custom Javascript

It is recommended to put these extensions in the order specified and after all other extensions in the list.