path}$file"); } //No such thing as autoloading classes in javascript $model_files = array( 'ElggEntity', 'ElggUser', 'ElggPriorityList', ); foreach ($model_files as $file) { include("{$CONFIG->path}js/classes/$file.js"); } //Include library files $libs = array( //libraries 'prototypes', 'hooks', 'security', 'languages', 'ajax', 'session', 'pageowner', 'configuration', //ui 'ui', 'ui.widgets', ); foreach ($libs as $file) { include("{$CONFIG->path}js/lib/$file.js"); // putting a new line between the files to address http://trac.elgg.org/ticket/3081 echo "\n"; } /** * Set some values that are cacheable */ ?> elgg.version = ''; elgg.release = ''; elgg.config.wwwroot = ''; elgg.security.interval = 5 * 60 * 1000; elgg.config.domReady = false; elgg.config.language = 'language) ? $CONFIG->language : 'en'; ?>'; elgg.config.languageReady = false; //After the DOM is ready $(function() { elgg.config.domReady = true; elgg.initWhenReady(); });