aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCash Costello <cash.costello@gmail.com>2011-09-12 21:47:11 -0400
committerCash Costello <cash.costello@gmail.com>2011-09-12 21:47:11 -0400
commitd9392db5ecd670a46f25dfd1a9dd11bb3142af10 (patch)
treec712c3119c5d55df54e557ccdb8589603de1357b
parent2c61de1a32a4b9dbdf50d8e25109dc4130237f78 (diff)
downloadelgg-d9392db5ecd670a46f25dfd1a9dd11bb3142af10.tar.gz
elgg-d9392db5ecd670a46f25dfd1a9dd11bb3142af10.tar.bz2
Refs #3800 including jeditable on more admin pages
-rw-r--r--engine/lib/admin.php10
-rw-r--r--views/default/js/admin.php1
2 files changed, 5 insertions, 6 deletions
diff --git a/engine/lib/admin.php b/engine/lib/admin.php
index c16da9295..93ee43008 100644
--- a/engine/lib/admin.php
+++ b/engine/lib/admin.php
@@ -239,6 +239,9 @@ function admin_init() {
elgg_register_action('profile/fields/reorder', '', 'admin');
elgg_register_simplecache_view('js/admin');
+ $url = elgg_get_simplecache_url('js', 'admin');
+ elgg_register_js('elgg.admin', $url);
+ elgg_register_js('jquery.jeditable', 'vendors/jquery/jquery.jeditable.mini.js');
// administer
// dashboard
@@ -434,11 +437,7 @@ function admin_settings_page_handler($page) {
elgg_set_context('admin');
elgg_unregister_css('elgg');
- $url = elgg_get_simplecache_url('js', 'admin');
- elgg_register_js('elgg.admin', $url);
elgg_load_js('elgg.admin');
-
- elgg_register_js('jquery.jeditable', 'vendors/jquery/jquery.jeditable.mini.js');
elgg_load_js('jquery.jeditable');
// default to dashboard
@@ -548,9 +547,8 @@ function admin_markdown_page_handler($pages) {
elgg_set_context('admin');
elgg_unregister_css('elgg');
- $url = elgg_get_simplecache_url('js', 'admin');
- elgg_register_js('elgg.admin', $url);
elgg_load_js('elgg.admin');
+ elgg_load_js('jquery.jeditable');
elgg_load_library('elgg:markdown');
$plugin_id = elgg_extract(0, $pages);
diff --git a/views/default/js/admin.php b/views/default/js/admin.php
index 2f2f59287..253a73887 100644
--- a/views/default/js/admin.php
+++ b/views/default/js/admin.php
@@ -32,6 +32,7 @@ elgg.admin.init = function () {
});
// in-line editing for custom profile fields.
+ // @note this requires jquery.jeditable plugin
$(".elgg-state-editable").editable(elgg.admin.editProfileField, {
type: 'text',
onblur: 'submit',