Forums | Mahara Themes

General discussion /
Getting Started with Themes


anonymous profile picture
Account deleted
Posts: 2

02 August 2009, 19:14

Hi All,

I'm new to Mahara and have successfully installed 1.1.5 and wish to make some minor changes to the theme (the logo to start with).  I've seen reference to Smarty but that is completely new to me.  At this stage I just want to know how to copy and modify the default template.  However I can't even find the administrator setting for selecting a theme. Could someone give some basic help here?

Thanks in advance,  Mike Smith - Brisbane

anonymous profile picture
Account deleted
Posts: 1643

03 August 2009, 17:02

Hi Mike,

Our theme documentation is criminally lacking. I plan to fix this asap, in the meantime here are the steps for creating a new theme:

Create a new directory in the theme/ subdirectory (e.g. theme/ponies/ or similar)

Copy the config.php from the default theme directory to your new directory

Edit your config.php, remove the $theme->formrenderer line, and add a new line: $theme->parent = 'default';

From then on, you will have created a new theme that inherits from the default theme. What this means is, when Mahara needs a theme file (image, CSS file or template), it will look for it in your theme's directory, and if it can't find it there it will use the one in default/.

This means you can create e.g. the static/images directory, and put a logo.gif in it, and this will change the site logo Wink

You can do the same with static/style/*.css - those stylesheets will be included on the page after the parent theme's ones, so you just need to override rules you want to change. Unfortunately the default css has quite a bit of !important in it (all removed in 1.2), which will make the process a bit more annoying than it has to be.

Hope that's enough to get you started! 

anonymous profile picture
Account deleted
Posts: 23

17 October 2009, 10:36

Hi - New to Mahara and I'm looking to theme it.  I have created the folder MyMaharaTheme with an edited version of the config.php file in it as described below but it is not vision in the Site Admin section; all I get is default and no way to change it.

Is there something I have missed?  or neglected to do? 

anonymous profile picture
Account deleted
Posts: 3

17 October 2009, 12:49

Thankyou for that.  theme manipulation works perfectly.
anonymous profile picture
Account deleted
Posts: 1643

20 October 2009, 21:54

Hi - what version of Mahara were you trying this on? It should work fine for Mahara 1.1.X, though 1.2 has different instructions.

We put some better instructions on the wiki:  http://wiki.mahara.org/Customising/Themes

5 results