public function add_module_config($name, $config, $group = null) {
        if ($group) {
            if (!isset($this->groups[$name])) {
                throw new coding_exception('The Moodle YUI module does not exist. You must define the moodle module config using YUI_config->add_module_config first.');
            }
            if (!isset($this->groups[$group]['modules'])) {
                $this->groups[$group]['modules'] = array();
            }
            $modules = &$this->groups[$group]['modules'];
        } else {
            $modules = &$this->modules;
        }
        $modules[$name] = $config;
    }
public function add_module_config($name, $config, $group = null) {
        if ($group) {
            if (!isset($this->groups[$name])) {
                throw new coding_exception('The Moodle YUI module does not exist. You must define the moodle module config using YUI_config->add_module_config first.');
            }
            if (!isset($this->groups[$group]['modules'])) {
                $this->groups[$group]['modules'] = array();
            }
            $modules = &$this->groups[$group]['modules'];
        } else {
            $modules = &$this->modules;
        }
        $modules[$name] = $config;
    }
public function add_module_config ( $ name , $ config , $ group = null ) { if ( $ group ) { if ( ! isset ( $ this -> groups [ $ name ] ) ) { throw new coding_exception ( 'The Moodle YUI module does not exist. You must define the moodle module config using YUI_config->add_module_config first.' ) ; } if ( ! isset ( $ this -> groups [ $ group ] [ 'modules' ] ) ) { $ this -> groups [ $ group ] [ 'modules' ] = array ( ) ; } $ modules = & $ this -> groups [ $ group ] [ 'modules' ] ; } else { $ modules = & $ this -> modules ; } $ modules [ $ name ] = $ config ; }
Add configuration for a specific module.

@param String $name The name of the module to add configuration for.
@param Array $config The configuration for the specified module.
@param String $group The name of the group to add configuration for.
If not specified, then this module is added to the global
configuration.
@return void
Add configuration for a specific module .