From 6b740b9f365d75fb9765d23a042378d16a3abeb0 Mon Sep 17 00:00:00 2001
From: "jocuri%softhome.net" <>
Date: Sat, 14 Feb 2004 18:54:51 +0000
Subject: [PATCH] Patch for bug 234171; removes \%COOKIE from index.cgi; patch
by Teemu Mannermaa ; r=gerv; a=justdave.
---
index.cgi | 8 +-------
template/en/default/index.html.tmpl | 6 +++---
2 files changed, 4 insertions(+), 10 deletions(-)
diff --git a/index.cgi b/index.cgi
index f617965d34..bbe936207f 100755
--- a/index.cgi
+++ b/index.cgi
@@ -21,10 +21,6 @@
# Contributor(s): Jacob Steenhagen
#
-# Suppress silly "used only once" warnings
-use vars qw{ %COOKIE };
-
-
###############################################################################
# Script Initialization
###############################################################################
@@ -37,7 +33,6 @@ use lib ".";
require "CGI.pl";
use vars qw(
- $template
$vars
);
@@ -52,8 +47,7 @@ quietly_check_login('permit_anonymous');
###############################################################################
my $cgi = Bugzilla->cgi;
-
-$vars->{'username'} = $::COOKIE{'Bugzilla_login'} || '';
+my $template = Bugzilla->template;
# Return the appropriate HTTP response headers.
print $cgi->header();
diff --git a/template/en/default/index.html.tmpl b/template/en/default/index.html.tmpl
index dd35059e52..b8ea79826e 100644
--- a/template/en/default/index.html.tmpl
+++ b/template/en/default/index.html.tmpl
@@ -22,7 +22,7 @@
#%]
[%# INTERFACE:
- # username: string. The login name of the user, if any.
+ # This template has no interface.
#%]
[% PROCESS global/variables.none.tmpl %]
@@ -64,9 +64,9 @@ function addSidebar() {
Enter a new [% terms.bug %] report
Summary reports and charts
-[% IF username %]
+[% IF user.id %]
Change password or user preferences
- Logout [% username FILTER html %]
+ Logout [% user.login FILTER html %]
[% ELSE %]
Log in to an existing account
[% IF Param('createemailregexp') %]
--
2.47.2