Skip to content

Commit

Permalink
page title should be considered obsolete - if people
Browse files Browse the repository at this point in the history
 do want to customise the top header, we should
 direct them to using the top/bottom include
 functions which allow full customisation.
  • Loading branch information
mantis committed Oct 9, 2013
1 parent 99c2ded commit 6d6f093
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 22 deletions.
13 changes: 7 additions & 6 deletions config_defaults_inc.php
Expand Up @@ -792,12 +792,6 @@
*/
$g_window_title = 'MantisBT';

/**
* title at top of html page (empty by default, since there is a logo now)
* @global string $g_page_title
*/
$g_page_title = '';

/**
* Check for admin directory, database upgrades, etc.
* @global int $g_admin_checks
Expand Down Expand Up @@ -3347,6 +3341,13 @@
/**
* Specify your top/bottom include file (logos, banners, etc). If a top file is
* supplied, the default MantisBT logo at the top will be hidden.
* For example, you could include a centered title at the top of the page with:
*
* <div class="center"><span class="pagetitle">TITLE</span></div>
*
* The default banner which is removed if you use an include file can be found in html_api.php in
* the function called html_top_banner.
*
* @global string $g_top_include_page
*/
$g_top_include_page = '%absolute_path%';
Expand Down
19 changes: 3 additions & 16 deletions core/html_api.php
Expand Up @@ -34,7 +34,6 @@
* html_page_top2a
* html_head_end
* html_body_begin
* html_header
* html_top_banner
* html_login_info
* (print_project_menu_bar)
Expand Down Expand Up @@ -242,7 +241,6 @@ function html_page_top2a() {
html_head_end();
html_body_begin();
$g_error_send_page_header = false;
html_header();
html_top_banner();
}

Expand Down Expand Up @@ -460,18 +458,7 @@ function html_body_begin() {
}

/**
* (9) Print the title displayed at the top of the page
* @return null
*/
function html_header() {
$t_title = config_get( 'page_title' );
if( !is_blank( $t_title ) ) {
echo '<div class="center"><span class="pagetitle">', string_display( $t_title ), '</span></div>', "\n";
}
}

/**
* (10) Print a user-defined banner at the top of the page if there is one.
* (9) Print a user-defined banner at the top of the page if there is one.
* @return null
*/
function html_top_banner() {
Expand Down Expand Up @@ -509,7 +496,7 @@ function html_top_banner() {
}

/**
* (11) Print the user's account information
* (10) Print the user's account information
* Also print the select box where users can switch projects
* @return null
*/
Expand Down Expand Up @@ -596,7 +583,7 @@ function html_login_info() {
}

/**
* (12) Print a user-defined banner at the bottom of the page if there is one.
* (11) Print a user-defined banner at the bottom of the page if there is one.
* @return null
*/
function html_bottom_banner() {
Expand Down
1 change: 1 addition & 0 deletions core/obsolete.php
Expand Up @@ -165,3 +165,4 @@
config_obsolete( 'session_key' );
config_obsolete( 'dhtml_filters', 'use_dynamic_filters' );
config_obsolete( 'use_iis' );
config_obsolete( 'page_title', 'top_include_page' );

0 comments on commit 6d6f093

Please sign in to comment.