Overriding Course Format Pix Moodle 2.6.1

Overriding Course Format Pix Moodle 2.6.1

על ידי Dave Emsley בתאריך
מספר תגובות: 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

ממוצע דרוגים: -
בתגובה ל: Dave Emsley

Re: Overriding Course Format Pix Moodle 2.6.1

על ידי 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

בתגובה ל: Mary Evans

Re: Overriding Course Format Pix Moodle 2.6.1

על ידי Gareth J Barnard בתאריך
תמונה של Core developers תמונה של Particularly helpful Moodlers תמונה של Plugin developers

Acknowledged, please give me some time to find out.

בתגובה ל: Gareth J Barnard

Re: Overriding Course Format Pix Moodle 2.6.1

על ידי Gareth J Barnard בתאריך
תמונה של Core developers תמונה של Particularly helpful Moodlers תמונה של 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'.
בתגובה ל: Gareth J Barnard

Re: Overriding Course Format Pix Moodle 2.6.1

על ידי Gareth J Barnard בתאריך
תמונה של Core developers תמונה של Particularly helpful Moodlers תמונה של Plugin developers

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

בתגובה ל: Gareth J Barnard

Re: Overriding Course Format Pix Moodle 2.6.1

על ידי Gareth J Barnard בתאריך
תמונה של Core developers תמונה של Particularly helpful Moodlers תמונה של Plugin developers

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

בתגובה ל: Gareth J Barnard

Re: Overriding Course Format Pix Moodle 2.6.1

על ידי 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

בתגובה ל: Mary Evans

Re: Overriding Course Format Pix Moodle 2.6.1

על ידי Gareth J Barnard בתאריך
תמונה של Core developers תמונה של Particularly helpful Moodlers תמונה של Plugin developers

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