diff --git a/include/class.osticket.php b/include/class.osticket.php index 44f4143672b9e4b427fbace7e3ce4d1e71867f91..86d206f212d6450db9755ac4f5c77926ff2a53c8 100644 --- a/include/class.osticket.php +++ b/include/class.osticket.php @@ -30,6 +30,7 @@ class osTicket { var $warning; var $message; + var $title; //Custom title. html > head > title. var $headers; var $config; @@ -168,6 +169,14 @@ class osTicket { return $this->headers; } + function setPageTitle($title) { + $this->title = $title; + } + + function getPageTitle() { + return $this->title; + } + function getErrors() { return $this->errors; } diff --git a/include/staff/header.inc.php b/include/staff/header.inc.php index 4d947535638195bb097bbf7c2bf2d1782e2d1856..a349cb3c6ecb662f2d82f64086fc4984e295c263 100644 --- a/include/staff/header.inc.php +++ b/include/staff/header.inc.php @@ -4,7 +4,7 @@ <meta http-equiv="content-type" content="text/html; charset=UTF-8"> <meta http-equiv="cache-control" content="no-cache" /> <meta http-equiv="pragma" content="no-cache" /> - <title>osTicket Staff Control Panel</title> + <title><?php echo ($ost && ($title=$ost->getPageTitle()))?$title:'osTicket :: Staff Control Panel'; ?></title> <!--[if IE]> <style type="text/css"> .tip_shadow { display:block !important; } @@ -29,7 +29,7 @@ } ?> </head> -<body onunload=""> +<body> <div id="container"> <div id="header"> <a href="index.php" id="logo">osTicket - Customer Support System</a> diff --git a/scp/admin.inc.php b/scp/admin.inc.php index 28db6fab7ba04c5100a26e6dadc615deb121b7be..8a41c54db7f690b3caec9ee7728345bba1570000 100644 --- a/scp/admin.inc.php +++ b/scp/admin.inc.php @@ -59,4 +59,7 @@ if($ost->isUpgradePending()) { //Admin navigation - overwrites what was set in staff.inc.php $nav = new AdminNav($thisstaff); + +//Page title. +$ost->setPageTitle('osTicket :: Admin Control Panel'); ?> diff --git a/scp/staff.inc.php b/scp/staff.inc.php index decf2c5cd624a719f718d5e53e92770fc502ae4c..8553a8bac1fef78482532de7789723af43e6c20d 100644 --- a/scp/staff.inc.php +++ b/scp/staff.inc.php @@ -122,4 +122,7 @@ if($thisstaff->forcePasswdChange() && !$exempt) { require('profile.php'); //profile.php must request this file as require_once to avoid problems. exit; } + +$ost->setPageTitle('osTicket :: Staff Control Panel'); + ?> diff --git a/scp/tickets.php b/scp/tickets.php index 28d54abe53df2cee031e1c583cfce7fc15999689..b2a13ceae914b2a45be39417ef199a21cf7aa719 100644 --- a/scp/tickets.php +++ b/scp/tickets.php @@ -479,6 +479,7 @@ if($thisstaff->canCreateTickets()) { $inc = 'tickets.inc.php'; if($ticket) { + $ost->setPageTitle('Ticket #'.$ticket->getNumber()); $nav->setActiveSubMenu(-1); $inc = 'ticket-view.inc.php'; if($_REQUEST['a']=='edit' && $thisstaff->canEditTickets())