Moodle 2.5 layout for grades and reports

Moodle 2.5 layout for grades and reports

by Christos Savva -
Number of replies: 5

Hello to everyone, I am working on a custom theme for our Moodle 2.5, based on bootstrap but I have the following problem.

Everything works perfect except when I visit gradebook and Reports. The problem is that, when I visit these two sections my theme reverts to the parent css.

My config.php

$THEME->layouts = array(
'base' => array(
'file' => 'standard.php',
'regions' => array(),
),
'standard' => array(
'file' => 'standard.php',
'regions' => array('side-pre', 'side-post'),
'defaultregion' => 'side-post',
),
'course' => array(
'file' => 'standard.php',
'regions' => array('side-pre', 'side-post'),
'defaultregion' => 'side-post'
),
'coursecategory' => array(
'file' => 'standard.php',
'regions' => array('side-pre', 'side-post'),
'defaultregion' => 'side-post',
),
'incourse' => array(
'file' => 'standard.php',
'regions' => array('side-pre', 'side-post'),
'defaultregion' => 'side-post',
),
'frontpage' => array(
'file' => 'standard.php',
'regions' => array('side-pre', 'side-post'),
'defaultregion' => 'side-post',
),
'admin' => array(
'file' => 'standard.php',
'regions' => array('side-pre'),
'defaultregion' => 'side-pre',
),
'mydashboard' => array(
'file' => 'standard.php',
'regions' => array('side-pre', 'side-post'),
'defaultregion' => 'side-post',
'options' => array('langmenu'=>true),
),
'mypublic' => array(
'file' => 'standard.php',
'regions' => array('side-pre', 'side-post'),
'defaultregion' => 'side-post',
),
'login' => array(
'file' => 'standard.php',
'regions' => array(),
'options' => array('langmenu'=>true),
),
'popup' => array(
'file' => 'standard.php',
'regions' => array(),
'options' => array('nofooter'=>true),
),
'frametop' => array(
'file' => 'standard.php',
'regions' => array(),
'options' => array('nofooter'=>true),
),
'maintenance' => array(
'file' => 'standard.php',
'regions' => array(),
'options' => array('nofooter'=>true, 'nonavbar'=>true),
),
'print' => array(
'file' => 'standard.php',
'regions' => array(),
'options' => array('nofooter'=>true, 'nonavbar'=>false),
),
);


So I my guess is that I need to include these two sections in my layouts and set the file to standart.php, but I have no idea what are the names for these sections.

Can anyone help me with that? Are there any more new layouts that I need to add in my config.php

Thank you in advance.

Kind regards

Christos

Average of ratings: -
In reply to Christos Savva

Re: Moodle 2.5 layout for grades and reports

by Christos Savva -

Nevermind, I found it smile. For future reference, here is the layout for reports. (I should have guessed it earlier)

 

'report' => array(
'file' => 'standard.php',
'regions' => array(),
'defaultregion' => 'side-post',

)

I am still interested to learn if there are any more layouts that I didn't include in my config.php. 

 

 

In reply to Christos Savva

Re: Moodle 2.5 layout for grades and reports

by Mary Evans -

Hi Christos,

You seem to have missed off the regions array . It should look this...

'report' => array(
'file' => 'standard.php',
'regions' => array('side-pre'),
'defaultregion' => 'side-pre',
),

Also it should be side-pre and NOT side-post that you have.

Cheers
Mary

In reply to Christos Savva

Re: Moodle 2.5 layout for grades and reports

by Gareth Barnard -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Dear Christos,

I'm not sure how to fix the issue, but this - http://docs.moodle.org/dev/Themes_overview#Appendix_A - gives the list of all current layouts.

Cheers,

Gareth