Overriding Course Format Pix Moodle 2.6.1

Overriding Course Format Pix Moodle 2.6.1

by Dave Emsley -
Number of replies: 8

Hi There,

I've read http://docs.moodle.org/dev/Using_images_in_a_theme#Overriding_plugin_images and it all makes sense... up to a point.

I understand the format

/theme/themename/area/plugintype/pluginname/filename.gif

I'm trying to replace the close icon in the grid format so I used..

/theme/themename/pix_plugin/course/format/grid/close.gif

but that's a level too many and doesn't work.

 

Could anyone clarify please?

Cheers


Dave

Average of ratings: -
In reply to Dave Emsley

Re: Overriding Course Format Pix Moodle 2.6.1

by Mary Evans -

Hi

My first thoughts about this is that course/formats/ don't usually carry a pix directory so perhaps the initial idea of overriding icons at a lower level is perhaps a design fault either in Moodle or in the Grid format.

I know Gareth J. Barnard who made the Grid format is known for pushing the boundaries, with respect to Course Formats, so the best person to answer this is Gareth himself. It may well be that the pix needs to be in format directory.

I'll need to test this out.

Cheers

Mary

Average of ratings: Useful (1)
In reply to Mary Evans

Re: Overriding Course Format Pix Moodle 2.6.1

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

Acknowledged, please give me some time to find out.

In reply to Gareth J Barnard

Re: Overriding Course Format Pix Moodle 2.6.1

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

Two immediate things that stand out:

  1. You have a folder name of 'pix_plugin' and not 'pix_plugins' as stated in the docs.
  2. Try the path without 'course' in the path.  Because your example breaks '/theme/themename/area/plugintype/pluginname/filename.gif' so you should have '/theme/themename/pix_plugins/format/grid/close.gif'.
Average of ratings: Useful (1)
In reply to Gareth J Barnard

Re: Overriding Course Format Pix Moodle 2.6.1

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

And its 'close.png' not 'close.gif'.  What exact version of the Grid format are you using?

Average of ratings: Useful (1)
In reply to Gareth J Barnard

Re: Overriding Course Format Pix Moodle 2.6.1

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

Ok, just done a quick test and you need ''/theme/themename/pix_plugins/format/grid/close.png'.

Average of ratings: Useful (1)
In reply to Gareth J Barnard

Re: Overriding Course Format Pix Moodle 2.6.1

by Mary Evans -

Tested and yes this works...as you can see this needs to be moodle/theme/themename/pix_plugins/format/grid/close.png

pix_plugins

Average of ratings: Useful (1)
In reply to Mary Evans

Re: Overriding Course Format Pix Moodle 2.6.1

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

I've just updated http://docs.moodle.org/dev/Themes_overview#Files_and_folders as it was wrong for the folder paths.

Average of ratings: Useful (1)
In reply to Gareth J Barnard

Re: Overriding Course Format Pix Moodle 2.6.1

by Dave Emsley -

Fantastic support and advices, as always, from this community.

 

Many Thanks

 

Dave Emsley