Themes

 
 
Picture of Łukasz Styś
Odp: Re: Adding YUI javascripts to moodle themes pages
 

one step forward smile I added the css file into sheets definition in the config.php file and now this is fine. JS left, any help?

 
Average of ratings: -
It's only an avatar...
Re: Odp: Re: Adding YUI javascripts to moodle themes pages
Group DevelopersGroup Documentation writersGroup Particularly helpful MoodlersGroup Testers

What kind of help do you want?

If it is to know how to add the JS script to a js file, and then add this file name into your theme config.php then I have added your JS to the attached file and called it openButton.js. Here are the instructions for adding this into your theme.

Add the attached file to theme/yourthemename/javascript/
directory that you will need to create first.

Then add the following to your theme/yourthemename/config.php where yourthemename is the name of YOUR theme.

$THEME->javascripts = array('openButton');

Now you can remove the script in the header as the code added to the config will add the JS automatically into the header when the page loads.

Also to see any changes to CSS & JavaScript you will need to Purge all caches in Site Administration > Development > Purge all caches

HTH

Mary

 
Average of ratings: -