aboutsummaryrefslogtreecommitdiff
path: root/views/default/core/account
diff options
context:
space:
mode:
authorbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-03-12 21:51:07 +0000
committerbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-03-12 21:51:07 +0000
commit19b7ea9a394af6e8366c64faa77badb716d743a5 (patch)
tree81382762378c7e5c2f62f4208c5cf6ff3a048b1d /views/default/core/account
parent120488c29722c1cde9a4715ccbe0f1626d4738ae (diff)
downloadelgg-19b7ea9a394af6e8366c64faa77badb716d743a5.tar.gz
elgg-19b7ea9a394af6e8366c64faa77badb716d743a5.tar.bz2
Fixes #3065, #3089. Merged JS events and hooks to a single system. Updated plugins and core to use it. Added elgg.getURLFragment() and using it elgg.ui.popsUp().
git-svn-id: http://code.elgg.org/elgg/trunk@8671 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'views/default/core/account')
-rw-r--r--views/default/core/account/login_box.php2
-rw-r--r--views/default/core/account/login_dropdown.php11
2 files changed, 5 insertions, 8 deletions
diff --git a/views/default/core/account/login_box.php b/views/default/core/account/login_box.php
index 40b5f5637..274172bdb 100644
--- a/views/default/core/account/login_box.php
+++ b/views/default/core/account/login_box.php
@@ -20,7 +20,7 @@ echo elgg_view_module('aside', $title, $body);
<script type="text/javascript">
- elgg.register_event_handler('init', 'system', function() {
+ elgg.register_hook_handler('init', 'system', function() {
$('input[name=username]').focus();
});
</script>
diff --git a/views/default/core/account/login_dropdown.php b/views/default/core/account/login_dropdown.php
index f3f105be1..a1d64a768 100644
--- a/views/default/core/account/login_dropdown.php
+++ b/views/default/core/account/login_dropdown.php
@@ -1,8 +1,6 @@
<?php
/**
* Elgg drop-down login form
- *
- * @todo Forms 1.8: Convert to use elgg_view_form()
*/
if (elgg_is_logged_in()) {
@@ -19,12 +17,11 @@ $body = elgg_view_form('login', array('action' => "{$login_url}action/login"), a
<div id="login-dropdown">
<?php
echo elgg_view('output/url', array(
- 'href' => 'login',
+ 'href' => 'login#login-dropdown-box',
+ 'rel' => 'popup',
+ 'class' => 'elgg-button elgg-button-dropdown',
'text' => elgg_echo('login'),
));
echo elgg_view_module('dropdown', '', $body, array('id' => 'login-dropdown-box'));
?>
-</div>
-<script>
- $('#login-dropdown > a').attr('href', '#login-dropdown-box').addClass('elgg-toggler elgg-button elgg-button-dropdown');
-</script> \ No newline at end of file
+</div> \ No newline at end of file