9 if (typeof
elgg !=
'object') {
10 throw new Error(
'elgg configuration object is not defined! You must include the js/initialize_elgg view in html head before JS library files!');
17 $classes_dir =
'js/classes';
24 "$classes_dir/ElggEntity",
25 "$classes_dir/ElggUser",
26 "$classes_dir/ElggPriorityList",
29 "$lib_dir/prototypes",
36 "$lib_dir/configuration",
41 "$lib_dir/ui.widgets",
46 foreach (
$files as $file) {
47 readfile(
"{$root_path}$file.js");
58 elgg.version =
'<?php echo elgg_get_version(); ?>';
59 elgg.release =
'<?php echo elgg_get_version(true); ?>';
60 elgg.config.wwwroot =
'<?php echo elgg_get_site_url(); ?>';
67 var languagesUrl =
elgg.config.wwwroot +
'ajax/view/js/languages?language=' +
elgg.get_language();
68 if (
elgg.config.simplecache_enabled) {
69 languagesUrl +=
'&lc=' +
elgg.config.lastcache;
72 define(
'elgg', [
'jquery', languagesUrl],
function($,
translations) {
76 elgg.trigger_hook(
'init',
'system');
77 elgg.trigger_hook(
'ready',
'system');
90 elgg.trigger_hook(
'boot',
'system');
elgg_view_deprecated($view, array $vars, $suggestion, $version)
Display a view with a deprecation notice.
elgg_get_root_path()
Get the root directory path for this installation.
elgg echo
Translates a string.
elgg require
Throw an error if the required package isn't present.
elgg global
Pointer to the global context.
$CONFIG translations
String translations for the current language.
$CONFIG language
The current language for either the site or the user.
global $CONFIG
Core Elgg JavaScript file.
< script > function()
The function used to get results.