(Created page with "Some examples and proof of concept for using jQuery for enhancing Moodle usability. == Collapsible course list == <syntaxhighlight lang="javascript"> jQuery('.section h3').wrap...") |
|||
Línia 9: | Línia 9: | ||
jQuery(this).parent().find('ul.section').toggle(); | jQuery(this).parent().find('ul.section').toggle(); | ||
}) | }) | ||
jQuery('ul.section').hide(); | |||
</syntaxhighlight> | </syntaxhighlight> | ||
Revisió del 16:00, 6 nov 2011
Some examples and proof of concept for using jQuery for enhancing Moodle usability.
Collapsible course list
jQuery('.section h3').wrapInner('<a href="#" />')
.click( function(event) {
event.preventDefault();
jQuery(this).parent().find('ul.section').toggle();
})
jQuery('ul.section').hide();