Adding YUI javascripts to moodle themes pages

It's only an avatar...
Re: Odp: Re: Adding YUI javascripts to moodle themes pages
Core developersDocumentation writersParticularly helpful MoodlersPlugin developersTesters

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



Average of ratings: -