GavickPro Documentation

Add diverse background images across your Joomla site’s pages

Joomla’s templates generally have the same background style (image/color) for each and every page. By applying additional extensions to a specific page (various menu item) the background can be styled individually from the others, increasing the variety of your design without resorting to using multiple template styles.

There are few ways to add and use different background images (or/and colors) on different pages in Joomla.

IMPORTANT: Almost always you have to override body tag but there are exceptions, such a GK Game template where you have to override #gkBg .

Suffix Method (#1)

In the Features tab of the template settings you have an option, “Suffixes for pages” – where you can define a unique suffix (a CSS class) which will be added to the body tag on the specific page (you have to specify the menu item ID for the CSS class or component name – then the suffix will be used on all pages of the specific component).

So if you specify a suffix “ABC” (or “frontpage” as we did in our example) for the homepage (usually menu item ID = 640) then it will be appear in the body tag as:

   <body class="ABC">

and then you can specify a background for the homepage only using the following selector:

body.ABC { background: #FFFFE0 url('test.jpg');  }

Where you can add CSS tags responsible for background color and/or image. You can read here how to use custom CSS in Gavick templates.

Module method (#2)

Second method is based on using a background module. On JED you should find some extensions which should help you with this task. I mentioned about them below. When doing this remember about module assignment, about module position it doesn’t matter but I suggest to use “lang” position. Using modules, you have more flexibility, because you could have different bg images also for logged in/anonymous users.

Check is also another extension of this same developer named: HD-Custom CSS – which can also help you to implement custom CSS.

How to use a background module on selected pages

When using these modules note that you have to assign the chosen module to a page (menu item) where you want to change, more precisely “override”, the default background image.

Use Module Assignment tab in module configuration than choice of module assignment

Because in this CMS it’s possible to have different modules (and module copies) appear when you click different menu links.

Read also our other tips about background customization.

Add diverse background images across your Joomla site’s pages 4.455 (89.09%) 11 votes