aboutsummaryrefslogtreecommitdiff
path: root/mod/html5/views/default/page/walled_garden.php
blob: c12a7203d5f764ed1a37f6c8519c19f1ecf864cd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
<?php
/**
 * Walled garden page shell
 *
 * Used for the walled garden index page
 * 
 * @override views/default/page/walled_garden.php
 */

$is_sticky_register = elgg_is_sticky_form('register');
$wg_body_class = 'elgg-body-walledgarden';
if ($is_sticky_register) {
	$wg_body_class .= ' hidden';
}

// Set the content type
header("Content-type: text/html; charset=UTF-8");
?>
<!DOCTYPE html>
<html lang="<?php echo get_current_language(); ?>">
<head>
<?php echo elgg_view('page/elements/head', $vars); ?>
</head>
<body>
<div class="elgg-page elgg-page-walledgarden">
	<div class="elgg-page-messages">
		<?php echo elgg_view('page/elements/messages', array('object' => $vars['sysmessages'])); ?>
	</div>
	<div class="<?php echo $wg_body_class; ?>">
		<?php echo $vars['body']; ?>
	</div>
</div>
<?php if ($is_sticky_register): ?>
<script type="text/javascript">
elgg.register_hook_handler('init', 'system', function() {
	$('.registration_link').trigger('click');
});
</script>
<?php endif; ?>
<?php echo elgg_view('page/elements/foot'); ?>
</body>
</html>