From 3aab4367fb1644f7109880e0ef17cad418951dbf Mon Sep 17 00:00:00 2001 From: secretr Date: Sun, 21 Dec 2008 11:47:29 +0000 Subject: [PATCH] administration cleanup/minor improvements --- e107_admin/frontpage.php | 5 ++--- e107_files/jslib/core/admin.js | 12 ++++++------ e107_themes/_blank/admin_style.css | 2 +- e107_themes/_blank/theme.php | 4 +++- 4 files changed, 12 insertions(+), 11 deletions(-) diff --git a/e107_admin/frontpage.php b/e107_admin/frontpage.php index 302fd3cba..8ca74d7ca 100644 --- a/e107_admin/frontpage.php +++ b/e107_admin/frontpage.php @@ -9,8 +9,8 @@ * Administration Area - Front page * * $Source: /cvs_backup/e107_0.8/e107_admin/frontpage.php,v $ - * $Revision: 1.9 $ - * $Date: 2008-12-21 10:58:35 $ + * $Revision: 1.10 $ + * $Date: 2008-12-21 11:47:29 $ * $Author: secretr $ * */ @@ -25,7 +25,6 @@ $e_sub_cat = 'frontpage'; require_once ('auth.php'); require_once (e_HANDLER.'form_handler.php'); require_once (e_HANDLER."message_handler.php"); -$rs = new form(); $frm = new e_form(); $emessage = &eMessage::getInstance(); diff --git a/e107_files/jslib/core/admin.js b/e107_files/jslib/core/admin.js index a6029a3c3..dcbfda965 100644 --- a/e107_files/jslib/core/admin.js +++ b/e107_files/jslib/core/admin.js @@ -8,8 +8,8 @@ * e107 Admin Helper * * $Source: /cvs_backup/e107_0.8/e107_files/jslib/core/admin.js,v $ - * $Revision: 1.7 $ - * $Date: 2008-12-19 14:01:07 $ + * $Revision: 1.8 $ + * $Date: 2008-12-21 11:47:29 $ * $Author: secretr $ * */ @@ -219,7 +219,7 @@ e107Admin.AdminMenu = { show = $(show); if(!show) return false; if(this.activeTab && this.activeTab.identify() != show.identify()) { - if(container) $(container).select('a.link-active[href^=#])').invoke('removeClassName', 'link-active').invoke('addClassName', 'link'); + if(container) $(container).select('a.link-active[href^=#])').each(function (element) { element.removeClassName('link-active').addClassName('link') }); this.activeTab.hide(); this.activeTab = show; this.activeTab.removeClassName('e-hideme').show(); @@ -227,12 +227,12 @@ e107Admin.AdminMenu = { this.activeBar.removeClassName('link').addClassName('link-active'); return true; } else if(!this.activeTab) { //init - if(container) $(container).select('a.link-active[href^=#])').invoke('removeClassName', 'link-active').invoke('addClassName', 'link'); + if(container) $(container).select('a.link-active[href^=#])').each(function (element) { element.removeClassName('link-active').addClassName('link') }); this.activeTab = show.removeClassName('e-hideme').show(); if(bar) this.activeBar = bar.removeClassName('link').addClassName('link-active'); return true; } else if(!this.activeBar && this.activeTab) {//only bar is unknown - if(container) $(container).select('a.link-active[href^=#])').invoke('removeClassName', 'link-active').invoke('addClassName', 'link'); + if(container) $(container).select('a.link-active[href^=#])').each(function (element) { element.removeClassName('link-active').addClassName('link') }); if(bar) this.activeBar = bar.removeClassName('link').addClassName('link-active'); return true; } @@ -242,7 +242,7 @@ e107Admin.AdminMenu = { observer: function(event, cont) { if(this.switchTab(event.element().hash.substr(1), event.element(), cont)) { event.stop(); - document.location.hash = this.id.camelize() + 'AdminMenu=' + event.element().hash.substr(1) + document.location.hash = this.id.camelize() + 'AdminMenu=' + event.element().hash.substr(1); } }, diff --git a/e107_themes/_blank/admin_style.css b/e107_themes/_blank/admin_style.css index d57fdeac2..798ab1559 100644 --- a/e107_themes/_blank/admin_style.css +++ b/e107_themes/_blank/admin_style.css @@ -88,7 +88,6 @@ ul,ol { list-style:none; } .adminlist { width:100%; border:1px solid #ddd;} .adminlist th { padding: 5px; border-bottom:1px solid #ddd; border-right: 1px solid #ddd; font-weight: bold; white-space:nowrap; } .adminlist td { padding: 5px; border-bottom:1px solid #ddd; border-right: 1px solid #ddd; } - .adminlist th.last, .adminlist td.last { border-right: 0px solid;} .adminlist tr.last td{ border-bottom: 0px solid;} @@ -329,6 +328,7 @@ input.action.edit {} .admin-page-body { padding: 20px 15px 0; } .admin-footer {} legend { font-size: 14px; font-weight: bold; padding: 5px; } +.admin-help p { margin-bottom: 10px } /* help side menu */ /******** Layout */ .main-table { width: 100%; border: 0 none; } diff --git a/e107_themes/_blank/theme.php b/e107_themes/_blank/theme.php index f1f61be9f..2d7203759 100644 --- a/e107_themes/_blank/theme.php +++ b/e107_themes/_blank/theme.php @@ -43,6 +43,8 @@ function theme_head() { function tablestyle($caption, $text, $mod) { global $style; + $class = ''; + if(is_string($mod) && $mod == 'admin_help') $class = ' '.str_replace('_', '-', $mod); switch($style) { case 'admin_menu' : @@ -56,7 +58,7 @@ function tablestyle($caption, $text, $mod) { case 'site_info' : echo ' -
+

'.$caption.'

'.$text.'