44         $options[
'joins'][] = 
"join {$CONFIG->dbprefix}users_entity u on e.guid=u.guid";
 
   46         $options[
'joins'] = array(
"join {$CONFIG->dbprefix}users_entity u on e.guid=u.guid");
 
   53         $options[
'wheres'][] = 
"u.admin = 'yes'";
 
   55         $options[
'wheres'][] = 
"u.admin = 'yes'";
 
  151         $href = 
"admin/$parent_id/$menu_id";
 
  158         $name = 
"$parent_id:$name";
 
  165         'context' => 
'admin',
 
  166         'parent_name' => $parent_id,
 
  168         'section' => $section
 
  184             'href' => 
'admin/upgrades',
 
  185             'text' => 
elgg_echo(
'admin:view_upgrades'),
 
  210             'name' => 
'maintenance_mode',
 
  211             'href' => 
'admin/administer_utilities/maintenance',
 
  212             'text' => 
elgg_echo(
'admin:maintenance_mode:indicator_menu_item'),
 
  251     elgg_register_js(
'jquery.jeditable', 
'vendors/jquery/jquery.jeditable.mini.js');
 
  256         'name' => 
'dashboard',
 
  257         'href' => 
'admin/dashboard',
 
  259         'context' => 
'admin',
 
  261         'section' => 
'administer' 
  280         'name' => 
'upgrades',
 
  281         'href' => 
'admin/upgrades',
 
  283         'context' => 
'admin',
 
  285         'section' => 
'configure' 
  291         'href' => 
'admin/plugins',
 
  293         'context' => 
'admin',
 
  295         'section' => 
'configure' 
  322             'name' => 
'administration',
 
  331     $widgets = array(
'online_users', 
'new_users', 
'content_stats', 
'banned_users', 
'admin_welcome', 
'control_panel', 
'cron_status');
 
  370             'name' => 
'admin_logout',
 
  371             'href' => 
'action/logout',
 
  373             'is_trusted' => 
true,
 
  378             'name' => 
'view_site',
 
  381             'is_trusted' => 
true,
 
  386             'name' => 
'admin_profile',
 
  394                 'name' => 
'maintenance',
 
  395                 'href' => 
'admin/administer_utilities/maintenance',
 
  396                 'text' => 
elgg_echo(
'admin:administer_utilities:maintenance'),
 
  397                 'link_class' => 
'elgg-maintenance-mode-warning',
 
  406             'href' => 
'http://learn.elgg.org/en/stable/appendix/faqs.html',
 
  411             'text' => 
elgg_echo(
'admin:footer:manual'),
 
  412             'href' => 
'http://learn.elgg.org/en/stable/admin/index.html',
 
  416             'name' => 
'community_forums',
 
  417             'text' => 
elgg_echo(
'admin:footer:community_forums'),
 
  418             'href' => 
'http://community.elgg.org/groups/all/',
 
  423             'text' => 
elgg_echo(
'admin:footer:blog'),
 
  424             'href' => 
'https://community.elgg.org/blog/all',
 
  442     if (!$active_plugins) {
 
  447     foreach ($active_plugins as 
$plugin) {
 
  454                 'href' => 
"admin/plugin_settings/$plugin_id",
 
  455                 'text' => 
$plugin->getManifest()->getName(),
 
  456                 'parent_name' => 
'settings',
 
  457                 'context' => 
'admin',
 
  458                 'section' => 
'configure',
 
  477     $configure_items = 
$return[
'configure'];
 
  478     if (is_array($configure_items)) {
 
  480         foreach ($configure_items as $menu_item) {
 
  481             if ($menu_item->getName() == 
'settings') {
 
  490             $site_settings = array_splice(
$children, 0, 2);
 
  491             usort(
$children, array(
'\ElggMenuBuilder', 
'compareByText'));
 
  492             array_splice(
$children, 0, 0, $site_settings);
 
  517     if (!isset($page[0]) || empty($page[0])) {
 
  518         $page = array(
'dashboard');
 
  523     if (empty($page[count($page) - 1])) {
 
  527     $vars = array(
'page' => $page);
 
  530     if ($page[0] == 
'plugin_settings') {
 
  534             $view = 
'admin/plugin_settings';
 
  543         $view = 
'admin/' . implode(
'/', $page);
 
  545         if (count($page) > 1) {
 
  578     $filename_parts = array_slice(
$pages, 2);
 
  579     $filename = implode(
'/', $filename_parts);
 
  587         if (!file_exists($file)) {
 
  592     header(
"Content-type: image/jpeg");
 
  602             echo file_get_contents($file);
 
  646     $text_files = 
$plugin->getAvailableTextFiles();
 
  648     if (!array_key_exists(
$filename, $text_files)) {
 
  653     $file_contents = file_get_contents($file);
 
  655     if (!$file_contents) {
 
  667     $text = Markdown($file_contents);
 
  672         'content' => 
'<div class="elgg-markdown">' . 
$text . 
'</div>',
 
  687     header(
"Content-type: text/plain;charset=utf-8");
 
  690     if ($plugin_content) {
 
  708     $current_path = preg_replace(
'~^https?~', 
'', $current_url);
 
  709     if (0 === strpos($current_path, $site_path)) {
 
  710         $current_path = ($current_path === $site_path) ? 
'' : substr($current_path, strlen($site_path));
 
  712         $current_path = 
false;
 
  717         'current_path' => $current_path,
 
  718         'current_url' => $current_url,
 
  733     if ($info[
'identifier'] == 
'action' && $info[
'segments'][0] == 
'login') {
 
  744     $message = 
$site->getPrivateSetting(
'elgg_maintenance_message');
 
  751     header(
"HTTP/1.1 503 Service Unavailable");
 
  776     if (
$type == 
'login') {
 
  821     $adminWidgets = array(
 
  822         1 => array(
'control_panel', 
'admin_welcome'),
 
  823         2 => array(
'online_users', 
'new_users', 
'content_stats'),
 
  826     foreach ($adminWidgets as 
$column => $handlers) {
 
  840     $events->registerHandler(
'init', 
'system', 
'_elgg_admin_init');
 
if(! $owner||!($owner instanceof ElggUser)||! $owner->canEdit()) $error
 
if(! $collection_name) $id
 
elgg_register_action($action, $filename="", $access='logged_in')
Registers an action.
 
if($guid==elgg_get_logged_in_user_guid()) $name
 
elgg_get_simplecache_url($type, $view)
 
elgg_register_simplecache_view($view_name)
Registers a view to simple cache.
 
elgg_get_site_url($site_guid=0)
Get the URL for the current (or specified) site.
 
elgg_get_config($name, $site_guid=0)
Get an Elgg configuration value.
 
elgg_get_root_path()
Get the root directory path for this installation.
 
$guid
Removes an admin notice.
 
register_error($error)
Display an error on next page load.
 
elgg_register_css($name, $url, $priority=null)
Register a CSS file for inclusion in the HTML head.
 
elgg_extract($key, $array, $default=null, $strict=true)
Checks for $array[$key] and returns its value if it exists, else returns $default.
 
sanitise_filepath($path, $append_slash=true)
Sanitise file paths ensuring that they begin and end with slashes etc.
 
elgg_load_css($name)
Load a CSS file for this page.
 
elgg_register_plugin_hook_handler($hook, $type, $callback, $priority=500)
 
elgg_register_js($name, $url, $location='head', $priority=null)
Register a JavaScript file for inclusion.
 
elgg_unregister_plugin_hook_handler($hook, $entity_type, $callback)
Unregister a callback as a plugin hook.
 
elgg_register_event_handler($event, $object_type, $callback, $priority=500)
 
elgg_trigger_plugin_hook($hook, $type, $params=null, $returnvalue=null)
 
elgg_load_library($name)
Load a PHP library.
 
elgg_unregister_css($name)
Unregister a CSS file.
 
elgg_load_js($name)
Load a JavaScript resource on this page.
 
forward($location="", $reason='system')
Forward to $location.
 
elgg_set_ignore_access($ignore=true)
Set if Elgg's access system should be ignored.
 
_elgg_admin_maintenance_allow_url($current_url)
When in maintenance mode, should the given URL be handled normally?
 
_elgg_admin_plugin_screenshot_page_handler($pages)
Serves up screenshots for plugins from admin_plugin_screenshot/<plugin_id>/<size>/<ss_name>.
 
_elgg_admin_add_plugin_settings_menu()
Create the plugin settings page menu.
 
elgg_admin_notice_exists($id)
Check if an admin notice is currently active.
 
_elgg_admin_pagesetup()
Handles any set up required for administration pages.
 
_elgg_admin_init()
Initialize the admin backend.
 
elgg_delete_admin_notice($id)
Remove an admin notice by ID.
 
elgg_register_admin_menu_item($section, $menu_id, $parent_id=null, $priority=100)
Add an admin area section or child section.
 
_elgg_admin_maintenance_action_check($hook, $type)
Prevent non-admins from using actions.
 
elgg_add_admin_notice($id, $message)
Write a persistent message to the admin view.
 
elgg_get_admin_notices($limit=10)
Get admin notices.
 
_elgg_admin_markdown_page_handler($pages)
Formats and serves out markdown files from plugins.
 
_elgg_add_admin_widgets($event, $type, $user)
Adds default admin widgets to the admin dashboard.
 
_elgg_robots_page_handler()
Handle request for robots.txt.
 
elgg_get_admins(array $options=array())
Get the admin users.
 
_elgg_admin_page_handler($page)
Handle admin pages.
 
_elgg_create_notice_of_pending_upgrade($event, $type, $object)
Add an admin notice when a new \ElggUpgrade object is created.
 
_elgg_admin_maintenance_handler($hook, $type, $info)
Handle requests when in maintenance mode.
 
_elgg_admin_sort_page_menu($hook, $type, $return, $params)
Sort the plugin settings menu items.
 
elgg_echo($message_key, $args=array(), $language="")
Given a message key, returns an appropriately translated full-text string.
 
elgg_register_menu_item($menu_name, $menu_item)
Register an item for an Elgg menu.
 
elgg_is_menu_item_registered($menu_name, $item_name)
Check if a menu item has been registered.
 
elgg_get_plugin_from_id($plugin_id)
Returns an \ElggPlugin object with the path $path.
 
elgg_get_plugins($status='active', $site_guid=null)
Returns an ordered list of plugins.
 
get_entity($guid)
Loads and returns an entity object from a guid.
 
elgg_get_entities(array $options=array())
Returns an array of entities with optional filtering.
 
get_resized_image_from_existing_file($input_name, $maxwidth, $maxheight, $square=false, $x1=0, $y1=0, $x2=0, $y2=0, $upscale=false)
Gets the jpeg contents of the resized version of an already uploaded image (Returns false if the file...
 
elgg_register_page_handler($identifier, $function)
Registers a page handler for a particular identifier.
 
elgg_admin_gatekeeper()
Used at the top of a page to mark it as admin only.
 
elgg_in_context($context)
Check if this context exists anywhere in the stack.
 
elgg_set_context($context)
Sets the page context.
 
elgg_is_admin_logged_in()
Returns whether or not the viewer is currently logged in and an admin user.
 
elgg_get_logged_in_user_entity()
Return the current logged in user, or null if no user is logged in.
 
elgg_get_site_entity($site_guid=0)
Get an \ElggSite entity (default is current site)
 
get_user_by_email($email)
Get an array of users from an email address.
 
get_user_by_username($username)
Get user by username.
 
clearfix elgg elgg elgg elgg page header
 
$vars['type']
Install create admin account page.
 
elgg_view_layout($layout_name, $vars=array())
Displays a layout with optional parameters.
 
elgg_view_page($title, $body, $page_shell='default', $vars=array())
Assembles and outputs a full page.
 
elgg_view($view, $vars=array(), $bypass=false, $ignored=false, $viewtype='')
Return a parsed view.
 
elgg_view_icon($name, $vars=array())
View one of the elgg sprite icons.
 
elgg_view_exists($view, $viewtype='', $recurse=true)
Returns whether the specified view exists.