Elgg  Version 1.11
login.php
Go to the documentation of this file.
1 <?php
14 if (elgg_is_logged_in()) {
15  forward('');
16 }
17 
18 $title = elgg_echo('login');
19 $content = elgg_view('core/account/login_box', array('title' => false));
20 
21 if (elgg_get_config('walled_garden')) {
22  elgg_load_css('elgg.walled_garden');
23  $body = elgg_view_layout('walled_garden', array('content' => $content));
24  echo elgg_view_page($title, $body, 'walled_garden');
25 } else {
26  $body = elgg_view_layout('one_column', array(
27  'title' => $title,
28  'content' => $content,
29  ));
31 }
elgg_get_config($name, $site_guid=0)
Get an Elgg configuration value.
elgg_is_logged_in()
Returns whether or not the user is currently logged in.
Definition: sessions.php:51
elgg forward
Meant to mimic the php forward() function by simply redirecting the user to another page...
Definition: elgglib.js:419
if(elgg_is_logged_in()) $title
Definition: login.php:18
elgg_load_css($name)
Load a CSS file for this page.
Definition: elgglib.php:255
elgg_echo($message_key, $args=array(), $language="")
Given a message key, returns an appropriately translated full-text string.
Definition: languages.php:21
$content
Definition: login.php:19
elgg echo
Translates a string.
Definition: languages.js:43
elgg_view($view, $vars=array(), $bypass=false, $ignored=false, $viewtype= '')
Return a parsed view.
Definition: views.php:354
elgg_view_layout($layout_name, $vars=array())
Displays a layout with optional parameters.
Definition: views.php:622
elgg_view_page($title, $body, $page_shell= 'default', $vars=array())
Assembles and outputs a full page.
Definition: views.php:437