bugzilla.gnome.org r70 - in trunk: . Bugzilla Bugzilla/CVS Bugzilla/DB Bugzilla/DB/CVS Bugzilla/Install Bugzilla/Install/CVS Bugzilla/Search Bugzilla/Search/CVS Bugzilla/WebService Bugzilla/WebService/CVS CVS contrib contrib/CVS docs/xml docs/xml/CVS skins/standard skins/standard/CVS t t/CVS template/en/default template/en/default/CVS template/en/default/account template/en/default/account/CVS template/en/default/admin/classifications template/en/default/admin/classifications/CVS template/en/default/admin/groups template/en/default/admin/groups/CVS template/en/default/admin/params template/en/default/admin/params/CVS template/en/default/admin/users template/en/default/admin/users/CVS template/en/default/attachment template/en/default/attachment/CVS template/en/default/bug template/en/default/bug/CVS template/en/default/bug/activity template/en/default/bug/activity/CVS template/en/default/bug/create template/en/default/bug/create/CVS template/en/default/bug/process te mplate/en/default/bug/process/CVS template/en/default/email template/en/default/email/CVS template/en/default/flag template/en/default/flag/CVS template/en/default/global template/en/default/global/CVS template/en/default/pages template/en/default/pages/CVS template/en/default/search template/en/default/search/CVS



Author: ovitters
Date: Fri Apr 11 17:31:30 2008
New Revision: 70
URL: http://svn.gnome.org/viewvc/bugzilla.gnome.org?rev=70&view=rev

Log:
Merge changes made upstream.


Modified:
   trunk/Bugzilla/Bug.pm
   trunk/Bugzilla/BugMail.pm
   trunk/Bugzilla/CGI.pm
   trunk/Bugzilla/CVS/Entries
   trunk/Bugzilla/Config.pm
   trunk/Bugzilla/Constants.pm
   trunk/Bugzilla/DB.pm
   trunk/Bugzilla/DB/CVS/Entries
   trunk/Bugzilla/DB/Mysql.pm
   trunk/Bugzilla/Flag.pm
   trunk/Bugzilla/Install/CVS/Entries
   trunk/Bugzilla/Install/Requirements.pm
   trunk/Bugzilla/Mailer.pm
   trunk/Bugzilla/Search.pm
   trunk/Bugzilla/Search/CVS/Entries
   trunk/Bugzilla/Search/Quicksearch.pm
   trunk/Bugzilla/Template.pm
   trunk/Bugzilla/Token.pm
   trunk/Bugzilla/Update.pm
   trunk/Bugzilla/User.pm
   trunk/Bugzilla/WebService/Bug.pm
   trunk/Bugzilla/WebService/CVS/Entries
   trunk/Bugzilla/WebService/Constants.pm
   trunk/CVS/Entries
   trunk/UPGRADING-pre-2.8
   trunk/attachment.cgi
   trunk/buglist.cgi
   trunk/contrib/CVS/Entries
   trunk/contrib/merge-users.pl
   trunk/contrib/syncLDAP.pl
   trunk/docs/xml/Bugzilla-Guide.xml
   trunk/docs/xml/CVS/Entries
   trunk/docs/xml/administration.xml
   trunk/docs/xml/conventions.xml
   trunk/docs/xml/customization.xml
   trunk/docs/xml/faq.xml
   trunk/docs/xml/installation.xml
   trunk/docs/xml/modules.xml
   trunk/docs/xml/using.xml
   trunk/editproducts.cgi
   trunk/editusers.cgi
   trunk/email_in.pl
   trunk/mod_perl.pl
   trunk/process_bug.cgi
   trunk/query.cgi
   trunk/relogin.cgi
   trunk/skins/standard/CVS/Entries
   trunk/skins/standard/IE-fixes.css
   trunk/skins/standard/global.css
   trunk/t/004template.t
   trunk/t/CVS/Entries
   trunk/template/en/default/CVS/Entries
   trunk/template/en/default/account/CVS/Entries
   trunk/template/en/default/account/cancel-token.txt.tmpl
   trunk/template/en/default/admin/classifications/CVS/Entries
   trunk/template/en/default/admin/classifications/reclassify.html.tmpl
   trunk/template/en/default/admin/groups/CVS/Entries
   trunk/template/en/default/admin/groups/delete.html.tmpl
   trunk/template/en/default/admin/params/CVS/Entries
   trunk/template/en/default/admin/params/auth.html.tmpl
   trunk/template/en/default/admin/users/CVS/Entries
   trunk/template/en/default/admin/users/confirm-delete.html.tmpl
   trunk/template/en/default/admin/users/userdata.html.tmpl
   trunk/template/en/default/attachment/CVS/Entries
   trunk/template/en/default/attachment/edit.html.tmpl
   trunk/template/en/default/attachment/show-multiple.html.tmpl
   trunk/template/en/default/bug/CVS/Entries
   trunk/template/en/default/bug/activity/CVS/Entries
   trunk/template/en/default/bug/activity/table.html.tmpl
   trunk/template/en/default/bug/comments.html.tmpl
   trunk/template/en/default/bug/create/CVS/Entries
   trunk/template/en/default/bug/create/create.html.tmpl
   trunk/template/en/default/bug/field.html.tmpl
   trunk/template/en/default/bug/process/CVS/Entries
   trunk/template/en/default/bug/process/midair.html.tmpl
   trunk/template/en/default/email/CVS/Entries
   trunk/template/en/default/email/votes-removed.txt.tmpl
   trunk/template/en/default/flag/CVS/Entries
   trunk/template/en/default/flag/list.html.tmpl
   trunk/template/en/default/global/CVS/Entries
   trunk/template/en/default/global/header.html.tmpl
   trunk/template/en/default/global/user-error.html.tmpl
   trunk/template/en/default/global/variables.none.tmpl
   trunk/template/en/default/pages/CVS/Entries
   trunk/template/en/default/pages/fields.html.tmpl
   trunk/template/en/default/pages/linked.html.tmpl
   trunk/template/en/default/pages/quicksearchhack.html.tmpl
   trunk/template/en/default/pages/release-notes.html.tmpl
   trunk/template/en/default/search/CVS/Entries
   trunk/template/en/default/search/form.html.tmpl
   trunk/template/en/default/welcome-admin.html.tmpl
   trunk/token.cgi
   trunk/userprefs.cgi
   trunk/whine.pl
   trunk/whineatnews.pl

Modified: trunk/Bugzilla/Bug.pm
==============================================================================
--- trunk/Bugzilla/Bug.pm	(original)
+++ trunk/Bugzilla/Bug.pm	Fri Apr 11 17:31:30 2008
@@ -99,13 +99,8 @@
 }
 
 use constant REQUIRED_CREATE_FIELDS => qw(
-    bug_severity
-    comment
     component
-    op_sys
-    priority
     product
-    rep_platform
     short_desc
     version
 );
@@ -130,11 +125,17 @@
         status_whiteboard => \&_check_status_whiteboard,
     };
 
-    my @select_fields = Bugzilla->get_fields({custom => 1, obsolete => 0,
-                                              type => FIELD_TYPE_SINGLE_SELECT});
+    my @custom_fields = Bugzilla->get_fields({custom => 1, obsolete => 0});
 
-    foreach my $field (@select_fields) {
-        $validators->{$field->name} = \&_check_select_field;
+    foreach my $field (@custom_fields) {
+        my $validator;
+        if ($field->type == FIELD_TYPE_SINGLE_SELECT) {
+            $validator = \&_check_select_field;
+        }
+        elsif ($field->type == FIELD_TYPE_FREETEXT) {
+            $validator = \&_check_freetext_field;
+        }
+        $validators->{$field->name} = $validator if $validator;
     }
     return $validators;
 };
@@ -239,11 +240,23 @@
 # C<deadline>       - For time-tracking. Will be ignored for the same
 #                     reasons as C<estimated_time>.
 sub create {
-    my $class  = shift;
+    my ($class, $params) = @_;
     my $dbh = Bugzilla->dbh;
 
-    $class->check_required_create_fields(@_);
-    my $params = $class->run_create_validators(@_);
+    # These fields have default values which we can use if they are undefined.
+    $params->{bug_severity} = Bugzilla->params->{defaultseverity}
+      unless defined $params->{bug_severity};
+    $params->{priority} = Bugzilla->params->{defaultpriority}
+      unless defined $params->{priority};
+    $params->{op_sys} = Bugzilla->params->{defaultopsys}
+      unless defined $params->{op_sys};
+    $params->{rep_platform} = Bugzilla->params->{defaultplatform}
+      unless defined $params->{rep_platform};
+    # Make sure a comment is always defined.
+    $params->{comment} = '' unless defined $params->{comment};
+
+    $class->check_required_create_fields($params);
+    $params = $class->run_create_validators($params);
 
     # These are not a fields in the bugs table, so we don't pass them to
     # insert_create_data.
@@ -824,6 +837,18 @@
     return $version;
 }
 
+# Custom Field Validators
+
+sub _check_freetext_field {
+    my ($invocant, $text) = @_;
+
+    $text = (defined $text) ? trim($text) : '';
+    if (length($text) > MAX_FREETEXT_LENGTH) {
+        ThrowUserError('freetext_too_long', { text => $text });
+    }
+    return $text;
+}
+
 sub _check_select_field {
     my ($invocant, $value, $field) = @_;
     $value = trim($value);
@@ -1611,7 +1636,7 @@
 
         if ($activity_visible) {
             # This gets replaced with a hyperlink in the template.
-            $field =~ s/^Attachment// if $attachid;
+            $field =~ s/^Attachment\s*// if $attachid;
 
             # Check for the results of an old Bugzilla data corruption bug
             $incomplete_data = 1 if ($added =~ /^\?/ || $removed =~ /^\?/);
@@ -1751,7 +1776,6 @@
     if (scalar(@list)) {
         foreach my $ref (@list) {
             my ($name, $userid, $oldvotes, $votesperuser, $maxvotesperbug) = (@$ref);
-            my $s;
 
             $maxvotesperbug = min($votesperuser, $maxvotesperbug);
 
@@ -1765,23 +1789,13 @@
 
             my $removedvotes = $oldvotes - $newvotes;
 
-            $s = ($oldvotes == 1) ? "" : "s";
-            my $oldvotestext = "You had $oldvotes vote$s on this bug.";
-
-            $s = ($removedvotes == 1) ? "" : "s";
-            my $removedvotestext = "You had $removedvotes vote$s removed from this bug.";
-
-            my $newvotestext;
             if ($newvotes) {
                 $dbh->do("UPDATE votes SET vote_count = ? " .
                          "WHERE bug_id = ? AND who = ?",
                          undef, ($newvotes, $id, $userid));
-                $s = $newvotes == 1 ? "" : "s";
-                $newvotestext = "You still have $newvotes vote$s on this bug."
             } else {
                 $dbh->do("DELETE FROM votes WHERE bug_id = ? AND who = ?",
                          undef, ($id, $userid));
-                $newvotestext = "You have no more votes remaining on this bug.";
             }
 
             # Notice that we did not make sure that the user fit within the $votesperuser
@@ -1792,7 +1806,6 @@
             # Now lets send the e-mail to alert the user to the fact that their votes have
             # been reduced or removed.
             my $vars = {
-
                 'to' => $name . Bugzilla->params->{'emailsuffix'},
                 'bugid' => $id,
                 'reason' => $reason,
@@ -1800,19 +1813,17 @@
                 'votesremoved' => $removedvotes,
                 'votesold' => $oldvotes,
                 'votesnew' => $newvotes,
-
-                'votesremovedtext' => $removedvotestext,
-                'votesoldtext' => $oldvotestext,
-                'votesnewtext' => $newvotestext,
-
-                'count' => $removedvotes . "\n    " . $newvotestext
             };
 
+            my $voter = new Bugzilla::User($userid);
+            my $template = Bugzilla->template_inner($voter->settings->{'lang'}->{'value'});
+
             my $msg;
-            my $template = Bugzilla->template;
             $template->process("email/votes-removed.txt.tmpl", $vars, \$msg);
             push(@messages, $msg);
         }
+        Bugzilla->template_inner("");
+
         my $votes = $dbh->selectrow_array("SELECT SUM(vote_count) " .
                                           "FROM votes WHERE bug_id = ?",
                                           undef, $id) || 0;

Modified: trunk/Bugzilla/BugMail.pm
==============================================================================
--- trunk/Bugzilla/BugMail.pm	(original)
+++ trunk/Bugzilla/BugMail.pm	Fri Apr 11 17:31:30 2008
@@ -635,10 +635,12 @@
         if ($isnew) {
             $threadingmarker = "Message-ID: <bug-$id-" . $user->id . "$sitespec>";
         } else {
-            $threadingmarker = "In-Reply-To: <bug-$id-" . $user->id . "$sitespec>";
+            $threadingmarker = "In-Reply-To: <bug-$id-" . $user->id . "$sitespec>" .
+                            "\nReferences: <bug-$id-" . $user->id . "$sitespec>";
         }
     } else {
-        $threadingmarker = "In-Reply-To: <bug-$id\ bugzilla gnome org>";
+        $threadingmarker = "In-Reply-To: <bug-$id-" . $user->id . "$sitespec>" .
+                            "\nReferences: <bug-$id-" . $user->id . "$sitespec>";
     }
     
 

Modified: trunk/Bugzilla/CGI.pm
==============================================================================
--- trunk/Bugzilla/CGI.pm	(original)
+++ trunk/Bugzilla/CGI.pm	Fri Apr 11 17:31:30 2008
@@ -54,7 +54,10 @@
 # We need to do so, too, otherwise perl dies when the object is destroyed
 # and we don't have a DESTROY method (because CGI.pm's AUTOLOAD will |die|
 # on getting an unknown sub to try to call)
-sub DESTROY {};
+sub DESTROY {
+    my $self = shift;
+    $self->SUPER::DESTROY(@_);
+};
 
 sub new {
     my ($invocant, @args) = @_;

Modified: trunk/Bugzilla/CVS/Entries
==============================================================================
--- trunk/Bugzilla/CVS/Entries	(original)
+++ trunk/Bugzilla/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -9,11 +9,9 @@
 D/WebService////
 /.cvsignore/1.1/dummy timestamp from new-entry//TBUGZILLA-3_0-BRANCH
 /Auth.pm/1.20/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
-/CGI.pm/1.31/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
 /Chart.pm/1.15/Sun Apr  8 13:11:06 2007//TBUGZILLA-3_0-BRANCH
 /Classification.pm/1.11/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
 /Component.pm/1.15/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
-/Config.pm/1.70/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
 /FlagType.pm/1.37/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
 /Group.pm/1.19/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
 /Install.pm/1.12/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
@@ -22,21 +20,23 @@
 /Object.pm/1.11/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
 /Product.pm/1.24/dummy timestamp from new-entry//TBUGZILLA-3_0-BRANCH
 /Series.pm/1.14/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
-/Token.pm/1.52.2.1/Sun Apr  8 13:11:07 2007//TBUGZILLA-3_0-BRANCH
 /Util.pm/1.56.2.1/Sun Apr  8 13:11:07 2007//TBUGZILLA-3_0-BRANCH
 /Version.pm/1.12/Sun Apr  8 13:11:07 2007//TBUGZILLA-3_0-BRANCH
 /WebService.pm/1.5.2.1/Sun Apr  8 13:11:07 2007//TBUGZILLA-3_0-BRANCH
 /Field.pm/1.24.2.1/Sat May 12 19:37:51 2007//TBUGZILLA-3_0-BRANCH
-/Update.pm/1.5.2.3/Sat May 12 19:37:51 2007//TBUGZILLA-3_0-BRANCH
 /Attachment.pm/1.45.2.1/Sat Aug 11 20:17:20 2007//TBUGZILLA-3_0-BRANCH
-/Flag.pm/1.83.2.2/Sat Aug 11 20:17:20 2007//TBUGZILLA-3_0-BRANCH
-/DB.pm/1.93.2.3/Sun Sep  2 09:52:04 2007//TBUGZILLA-3_0-BRANCH
 /Error.pm/1.19.2.3/Sun Sep  2 09:52:04 2007//TBUGZILLA-3_0-BRANCH
-/Mailer.pm/1.7.2.5/Sun Sep  2 09:52:04 2007//TBUGZILLA-3_0-BRANCH
-/Bug.pm/1.171.2.2/Result of merge//TBUGZILLA-3_0-BRANCH
-/BugMail.pm/1.104.2.2/Result of merge//TBUGZILLA-3_0-BRANCH
-/Constants.pm/1.68.2.10/Result of merge//TBUGZILLA-3_0-BRANCH
 /Hook.pm/1.7.2.1/Tue Nov  6 20:18:13 2007//TBUGZILLA-3_0-BRANCH
-/Search.pm/1.145.2.1/Tue Nov  6 20:18:13 2007//TBUGZILLA-3_0-BRANCH
-/Template.pm/1.68.2.5/Result of merge//TBUGZILLA-3_0-BRANCH
-/User.pm/1.148.2.4/Result of merge//TBUGZILLA-3_0-BRANCH
+/Bug.pm/1.171.2.6/Result of merge//TBUGZILLA-3_0-BRANCH
+/BugMail.pm/1.104.2.3/Result of merge+Fri Apr 11 16:25:51 2008//TBUGZILLA-3_0-BRANCH
+/CGI.pm/1.31.2.1/Fri Apr 11 16:25:51 2008//TBUGZILLA-3_0-BRANCH
+/Config.pm/1.70.2.1/Fri Apr 11 16:25:51 2008//TBUGZILLA-3_0-BRANCH
+/Constants.pm/1.68.2.13/Result of merge//TBUGZILLA-3_0-BRANCH
+/DB.pm/1.93.2.5/Fri Apr 11 16:25:51 2008//TBUGZILLA-3_0-BRANCH
+/Flag.pm/1.83.2.3/Fri Apr 11 16:25:51 2008//TBUGZILLA-3_0-BRANCH
+/Mailer.pm/1.7.2.8/Fri Apr 11 16:25:51 2008//TBUGZILLA-3_0-BRANCH
+/Search.pm/1.145.2.2/Fri Apr 11 16:25:51 2008//TBUGZILLA-3_0-BRANCH
+/Template.pm/1.68.2.6/Result of merge//TBUGZILLA-3_0-BRANCH
+/Token.pm/1.52.2.2/Fri Apr 11 16:25:51 2008//TBUGZILLA-3_0-BRANCH
+/Update.pm/1.5.2.4/Fri Apr 11 16:25:51 2008//TBUGZILLA-3_0-BRANCH
+/User.pm/1.148.2.6/Result of merge//TBUGZILLA-3_0-BRANCH

Modified: trunk/Bugzilla/Config.pm
==============================================================================
--- trunk/Bugzilla/Config.pm	(original)
+++ trunk/Bugzilla/Config.pm	Fri Apr 11 17:31:30 2008
@@ -315,6 +315,17 @@
         # Now read the param back out from the sandbox
         %params = %{$s->varglob('param')};
     }
+    elsif ($ENV{'SERVER_SOFTWARE'}) {
+       # We're in a CGI, but the params file doesn't exist. We can't
+       # Template Toolkit, or even install_string, since checksetup
+       # might not have thrown an error. Bugzilla::CGI->new
+       # hasn't even been called yet, so we manually use CGI::Carp here
+       # so that the user sees the error.
+       require CGI::Carp;
+       CGI::Carp->import('fatalsToBrowser');
+       die "The $datadir/params file does not exist."
+           . ' You probably need to run checksetup.pl.',
+    }
     return \%params;
 }
 

Modified: trunk/Bugzilla/Constants.pm
==============================================================================
--- trunk/Bugzilla/Constants.pm	(original)
+++ trunk/Bugzilla/Constants.pm	Fri Apr 11 17:31:30 2008
@@ -139,6 +139,7 @@
     SAFE_PROTOCOLS
 
     MAX_LEN_QUERY_NAME
+    MAX_FREETEXT_LENGTH
 );
 
 @Bugzilla::Constants::EXPORT_OK = qw(contenttypes);
@@ -146,7 +147,7 @@
 # CONSTANTS
 #
 # Bugzilla version
-use constant BUGZILLA_VERSION => "3.0.2+";
+use constant BUGZILLA_VERSION => "3.0.3+";
 
 #
 # ControlMap constants for group_control_map.
@@ -387,6 +388,9 @@
 # The longest that a saved search name can be.
 use constant MAX_LEN_QUERY_NAME => 64;
 
+# Maximum length allowed for free text fields.
+use constant MAX_FREETEXT_LENGTH => 255;
+
 sub bz_locations {
     # We know that Bugzilla/Constants.pm must be in %INC at this point.
     # So the only question is, what's the name of the directory

Modified: trunk/Bugzilla/DB.pm
==============================================================================
--- trunk/Bugzilla/DB.pm	(original)
+++ trunk/Bugzilla/DB.pm	Fri Apr 11 17:31:30 2008
@@ -597,18 +597,21 @@
 
 sub bz_add_field_table {
     my ($self, $name) = @_;
-    my $table_schema = $self->_bz_schema->FIELD_TABLE_SCHEMA;
     # We do nothing if the table already exists.
     return if $self->bz_table_info($name);
-    my $indexes      = $table_schema->{INDEXES};
-    # $indexes is an arrayref, not a hash. In order to fix the keys,
-    # we have to fix every other item.
-    for (my $i = 0; $i < scalar @$indexes; $i++) {
-        next if ($i % 2 && $i != 0); # We skip 1, 3, 5, 7, etc.
-        $indexes->[$i] = $name . "_" . $indexes->[$i];
+
+    # Copy this so that we're not modifying the constant.
+    my %table_schema = %{ $self->_bz_schema->FIELD_TABLE_SCHEMA };
+    my %indexes = @{ $table_schema{INDEXES} };
+    my %fixed_indexes;
+    foreach my $key (keys %indexes) {
+        $fixed_indexes{$name . "_" . $key} = $indexes{$key};
     }
+    # INDEXES is supposed to be an arrayref, so we have to convert back.
+    my @indexes_array = %fixed_indexes;
+    $table_schema{INDEXES} = \ indexes_array;
     # We add this to the abstract schema so that bz_add_table can find it.
-    $self->_bz_schema->add_table($name, $table_schema);
+    $self->_bz_schema->add_table($name, \%table_schema);
     $self->bz_add_table($name);
 }
 
@@ -898,7 +901,6 @@
                   } if (!defined($attributes));
 
     # connect using our known info to the specified db
-    # Apache::DBI will cache this when using mod_perl
     my $self = DBI->connect($dsn, $user, $pass, $attributes)
         or die "\nCan't connect to the database.\nError: $DBI::errstr\n"
         . "  Is your database installed and up and running?\n  Do you have"

Modified: trunk/Bugzilla/DB/CVS/Entries
==============================================================================
--- trunk/Bugzilla/DB/CVS/Entries	(original)
+++ trunk/Bugzilla/DB/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -1,4 +1,4 @@
 D/Schema////
-/Mysql.pm/1.49/Result of merge//TBUGZILLA-3_0-BRANCH
 /Pg.pm/1.23.2.1/Sat Aug 11 20:17:21 2007//TBUGZILLA-3_0-BRANCH
 /Schema.pm/1.80.2.3/Result of merge//TBUGZILLA-3_0-BRANCH
+/Mysql.pm/1.49.2.1/Result of merge//TBUGZILLA-3_0-BRANCH

Modified: trunk/Bugzilla/DB/Mysql.pm
==============================================================================
--- trunk/Bugzilla/DB/Mysql.pm	(original)
+++ trunk/Bugzilla/DB/Mysql.pm	Fri Apr 11 17:31:30 2008
@@ -284,16 +284,8 @@
         print "\nISAM->MyISAM table conversion done.\n\n";
     }
 
-    # There is a bug in MySQL 4.1.0 - 4.1.15 that makes certain SELECT
-    # statements fail after a SHOW TABLE STATUS: 
-    # http://bugs.mysql.com/bug.php?id=13535
-    # This is a workaround, a dummy SELECT to reset the LAST_INSERT_ID.
     my @tables = $self->bz_table_list_real();
-    if (grep($_ eq 'bugs', @tables)
-        && $self->bz_column_info_real("bugs", "bug_id"))
-    {
-        $self->do('SELECT 1 FROM bugs WHERE bug_id IS NULL');
-    }
+    $self->_after_table_status(\ tables);
 
     # Versions of Bugzilla before the existence of Bugzilla::DB::Schema did 
     # not provide explicit names for the table indexes. This means
@@ -464,6 +456,17 @@
         } # foreach table
     } # if old-name indexes
 
+    # If there are no tables, but the DB isn't utf8 and it should be,
+    # then we should alter the database to be utf8. We know it should be
+    # if the utf8 parameter is true or there are no params at all.
+    # This kind of situation happens when people create the database
+    # themselves, and if we don't do this they will get the big
+    # scary WARNING statement about conversion to UTF8.
+    if ( !$self->bz_db_is_utf8 && ! tables 
+         && (Bugzilla->params->{'utf8'} || !scalar keys %{Bugzilla->params}) )
+    {
+        $self->_alter_db_charset_to_utf8();
+    }
 
     # And now we create the tables and the Schema object.
     $self->SUPER::bz_setup_database();
@@ -572,7 +575,16 @@
     }
 
     # Convert the database to UTF-8 if the utf8 parameter is on.
-    if (Bugzilla->params->{'utf8'} && !$self->bz_db_is_utf8) {
+    # We check if any table isn't utf8, because lots of crazy
+    # partial-conversion situations can happen, and this handles anything
+    # that could come up (including having the DB charset be utf8 but not
+    # the table charsets.
+    my $utf_table_status =
+        $self->selectall_arrayref("SHOW TABLE STATUS", {Slice=>{}});
+    $self->_after_table_status([map($_->{Name}, @$utf_table_status)]);
+    my @non_utf8_tables = grep($_->{Collation} !~ /^utf8/, @$utf_table_status);
+    
+    if (Bugzilla->params->{'utf8'} && scalar @non_utf8_tables) {
         print <<EOT;
 
 WARNING: We are about to convert your table storage format to UTF8. This
@@ -664,12 +676,37 @@
             $self->do("ALTER TABLE $table " . join(", ", @sql_utf8)) if @sql_utf8;
             $self->do("ALTER TABLE $table DEFAULT CHARACTER SET utf8");
         } # foreach my $table (@tables)
+    }
 
-        my $db_name = Bugzilla->localconfig->{db_name};
-        $self->do("ALTER DATABASE $db_name CHARACTER SET utf8");
+    # Sometimes you can have a situation where all the tables are utf8,
+    # but the database isn't. (This tends to happen when you've done
+    # a mysqldump.) So we have this change outside of the above block,
+    # so that it just happens silently if no actual *table* conversion
+    # needs to happen.
+    if (Bugzilla->params->{'utf8'} && !$self->bz_db_is_utf8) {
+        $self->_alter_db_charset_to_utf8();
     }
 }
 
+# There is a bug in MySQL 4.1.0 - 4.1.15 that makes certain SELECT
+# statements fail after a SHOW TABLE STATUS: 
+# http://bugs.mysql.com/bug.php?id=13535
+# This is a workaround, a dummy SELECT to reset the LAST_INSERT_ID.
+sub _after_table_status {
+    my ($self, $tables) = @_;
+    if (grep($_ eq 'bugs', @$tables)
+        && $self->bz_column_info_real("bugs", "bug_id"))
+    {
+        $self->do('SELECT 1 FROM bugs WHERE bug_id IS NULL');
+    }
+}
+
+sub _alter_db_charset_to_utf8 {
+    my $self = shift;
+    my $db_name = Bugzilla->localconfig->{db_name};
+    $self->do("ALTER DATABASE $db_name CHARACTER SET utf8"); 
+}
+
 sub bz_db_is_utf8 {
     my $self = shift;
     my $db_collation = $self->selectrow_arrayref(

Modified: trunk/Bugzilla/Flag.pm
==============================================================================
--- trunk/Bugzilla/Flag.pm	(original)
+++ trunk/Bugzilla/Flag.pm	Fri Apr 11 17:31:30 2008
@@ -1017,56 +1017,54 @@
 sub notify {
     my ($flag, $bug, $attachment) = @_;
 
-    my $template = Bugzilla->template;
-
     # There is nobody to notify.
     return unless ($flag->{'addressee'} || $flag->type->cc_list);
 
-    my $attachment_is_private = $attachment ? $attachment->isprivate : undef;
-
     # If the target bug is restricted to one or more groups, then we need
     # to make sure we don't send email about it to unauthorized users
     # on the request type's CC: list, so we have to trawl the list for users
     # not in those groups or email addresses that don't have an account.
     my @bug_in_groups = grep {$_->{'ison'} || $_->{'mandatory'}} @{$bug->groups};
+    my $attachment_is_private = $attachment ? $attachment->isprivate : undef;
 
-    if (scalar(@bug_in_groups) || $attachment_is_private) {
-        my @new_cc_list;
-        foreach my $cc (split(/[, ]+/, $flag->type->cc_list)) {
-            my $ccuser = new Bugzilla::User({ name => $cc }) || next;
-
-            next if (scalar(@bug_in_groups) && !$ccuser->can_see_bug($bug->bug_id));
-            next if $attachment_is_private
-              && Bugzilla->params->{"insidergroup"}
-              && !$ccuser->in_group(Bugzilla->params->{"insidergroup"});
-            push(@new_cc_list, $cc);
-        }
-        $flag->type->{'cc_list'} = join(", ", @new_cc_list);
+    my %recipients;
+    foreach my $cc (split(/[, ]+/, $flag->type->cc_list)) {
+        my $ccuser = new Bugzilla::User({ name => $cc });
+        next if (scalar(@bug_in_groups) && (!$ccuser || !$ccuser->can_see_bug($bug->bug_id)));
+        next if $attachment_is_private && (!$ccuser || !$ccuser->is_insider);
+        # Prevent duplicated entries due to case sensitivity.
+        $cc = $ccuser ? $ccuser->email : $cc;
+        $recipients{$cc} = $ccuser;
     }
 
-    # If there is nobody left to notify, return.
-    return unless ($flag->{'addressee'} || $flag->type->cc_list);
-
-    my @recipients = split(/[, ]+/, $flag->type->cc_list);
     # Only notify if the addressee is allowed to receive the email.
     if ($flag->{'addressee'} && $flag->{'addressee'}->email_enabled) {
-        push @recipients, $flag->{'addressee'}->email;
+        $recipients{$flag->{'addressee'}->email} = $flag->{'addressee'};
+    }
+    # Process and send notification for each recipient.
+    # If there are users in the CC list who don't have an account,
+    # use the default language for email notifications.
+    my $default_lang;
+    if (grep { !$_ } values %recipients) {
+        my $default_user = new Bugzilla::User();
+        $default_lang = $default_user->settings->{'lang'}->{'value'};
     }
-    # Process and send notification for each recipient
-    foreach my $to (@recipients)
-    {
-        next unless $to;
+
+    foreach my $to (keys %recipients) {
         my $vars = { 'flag'       => $flag,
                      'to'         => $to,
                      'bug'        => $bug,
                      'attachment' => $attachment};
+
+        my $lang = $recipients{$to} ?
+          $recipients{$to}->settings->{'lang'}->{'value'} : $default_lang;
+
+        my $template = Bugzilla->template_inner($lang);
         my $message;
-        my $rv = $template->process("request/email.txt.tmpl", $vars, \$message);
-        if (!$rv) {
-            Bugzilla->cgi->header();
-            ThrowTemplateError($template->error());
-        }
+        $template->process("request/email.txt.tmpl", $vars, \$message)
+          || ThrowTemplateError($template->error());
 
+        Bugzilla->template_inner("");
         MessageToMTA($message);
     }
 }

Modified: trunk/Bugzilla/Install/CVS/Entries
==============================================================================
--- trunk/Bugzilla/Install/CVS/Entries	(original)
+++ trunk/Bugzilla/Install/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -1,5 +1,5 @@
 /Localconfig.pm/1.8/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
 /DB.pm/1.26.2.3/Sat Aug 11 20:17:21 2007//TBUGZILLA-3_0-BRANCH
 /Filesystem.pm/1.18.2.2/Sun Sep  2 09:52:04 2007//TBUGZILLA-3_0-BRANCH
-/Requirements.pm/1.29.2.1/Tue Nov  6 20:18:14 2007//TBUGZILLA-3_0-BRANCH
+/Requirements.pm/1.29.2.4/Fri Apr 11 16:25:51 2008//TBUGZILLA-3_0-BRANCH
 D

Modified: trunk/Bugzilla/Install/Requirements.pm
==============================================================================
--- trunk/Bugzilla/Install/Requirements.pm	(original)
+++ trunk/Bugzilla/Install/Requirements.pm	Fri Apr 11 17:31:30 2008
@@ -56,11 +56,14 @@
 # are 'blacklisted'--that is, even if the version is high enough, Bugzilla
 # will refuse to say that it's OK to run with that version.
 sub REQUIRED_MODULES {
+    my $perl_ver = sprintf('%vd', $^V);
     my @modules = (
     {
         package => 'CGI',
         module  => 'CGI',
-        version => '2.93'
+        # Perl 5.10 requires CGI 3.33 due to a taint issue when
+        # uploading attachments, see bug 416382.
+        version => (vers_cmp($perl_ver, '5.10') > -1) ? '3.33' : '2.93'
     },
     {
         package => 'TimeDate',
@@ -212,22 +215,20 @@
         version => '1.999022',
         feature => 'mod_perl'
     },
+    );
+
     # Even very new releases of perl (5.8.5) don't come with this version,
     # so I didn't want to make it a general requirement just for
     # running under mod_cgi.
-    {
-        package => 'CGI',
-        module  => 'CGI',
-        version => '3.11',
-        feature => 'mod_perl'
-    },
-    {
-        package => 'Apache-DBI',
-        module  => 'Apache::DBI',
-        version => '0.96',
-        feature => 'mod_perl'
-    },
-    );
+    # If Perl 5.10 is installed, then CGI 3.33 is already required. So this
+    # check is only relevant with Perl 5.8.x.
+    my $perl_ver = sprintf('%vd', $^V);
+    if (vers_cmp($perl_ver, '5.10') < 0) {
+        push(@modules, { package => 'CGI',
+                         module  => 'CGI',
+                         version => '3.11',
+                         feature => 'mod_perl' });
+    }
 
     my $all_modules = _get_extension_requirements(
         'OPTIONAL_MODULES', \ modules);
@@ -307,6 +308,17 @@
     return %missing;
 }
 
+# Returns the build ID of ActivePerl. If several versions of
+# ActivePerl are installed, it won't be able to know which one
+# you are currently running. But that's our best guess.
+sub _get_activestate_build_id {
+    eval 'use Win32::TieRegistry';
+    return 0 if $@;
+    my $key = Win32::TieRegistry->new('LMachine\Software\ActiveState\ActivePerl')
+      or return 0;
+    return $key->GetValue("CurrentVersion");
+}
+
 sub print_module_instructions {
     my ($check_results, $output) = @_;
 
@@ -318,14 +330,19 @@
               . ROOT_USER . ".\n\n";
 
         if (ON_WINDOWS) {
-            print <<EOT;
-***********************************************************************
-* Note For Windows Users                                              *
-***********************************************************************
-* In order to install the modules listed below, you first have to run * 
-* the following command as an Administrator:                          *
-*                                                                     *
-*   ppm repo add theory58S http://theoryx5.uwinnipeg.ca/ppms          *
+            my $perl_ver = sprintf('%vd', $^V);
+            
+            # URL when running Perl 5.8.x.
+            my $url_to_theory58S = 'http://theoryx5.uwinnipeg.ca/ppms';
+            my $repo_up_cmd =
+'*                                                                     *';
+            # Packages for Perl 5.10 are not compatible with Perl 5.8.
+            if (vers_cmp($perl_ver, '5.10') > -1) {
+                $url_to_theory58S = 'http://cpan.uwinnipeg.ca/PPMPackages/10xx/';
+            }
+            # ActivePerl older than revision 819 require an additional command.
+            if (_get_activestate_build_id() < 819) {
+                $repo_up_cmd = <<EOT;
 *                                                                     *
 * Then you have to do (also as an Administrator):                     *
 *                                                                     *
@@ -333,6 +350,17 @@
 *                                                                     *
 * Do that last command over and over until you see "theory58S" at the *
 * top of the displayed list.                                          *
+EOT
+            }
+            print <<EOT;
+***********************************************************************
+* Note For Windows Users                                              *
+***********************************************************************
+* In order to install the modules listed below, you first have to run * 
+* the following command as an Administrator:                          *
+*                                                                     *
+*   ppm repo add theory58S $url_to_theory58S
+$repo_up_cmd
 ***********************************************************************
 EOT
         }

Modified: trunk/Bugzilla/Mailer.pm
==============================================================================
--- trunk/Bugzilla/Mailer.pm	(original)
+++ trunk/Bugzilla/Mailer.pm	Fri Apr 11 17:31:30 2008
@@ -44,6 +44,7 @@
 use Date::Format qw(time2str);
 
 use Encode qw(encode);
+use Encode::MIME::Header;
 use Email::Address;
 use Email::MIME;
 # Loading this gives us encoding_set.
@@ -68,6 +69,10 @@
     foreach my $header qw(From To Cc Reply-To Sender Errors-To Subject) {
         if (my $value = $email->header($header)) {
             $value = Encode::decode("UTF-8", $value) if Bugzilla->params->{'utf8'};
+
+            # avoid excessive line wrapping done by Encode.
+            local $Encode::Encoding{'MIME-Q'}->{'bpl'} = 998;
+
             my $encoded = encode('MIME-Q', $value);
             $email->header_set($header, $encoded);
         }
@@ -116,7 +121,8 @@
     if ($method eq "Test") {
         my $filename = bz_locations()->{'datadir'} . '/mailer.testfile';
         open TESTFILE, '>>', $filename;
-        print TESTFILE "\n\n---\n\n" . $email->as_string;
+        # From - <date> is required to be a valid mbox file.
+        print TESTFILE "\n\nFrom - " . $email->header('Date') . "\n" . $email->as_string;
         close TESTFILE;
     }
     else {

Modified: trunk/Bugzilla/Search.pm
==============================================================================
--- trunk/Bugzilla/Search.pm	(original)
+++ trunk/Bugzilla/Search.pm	Fri Apr 11 17:31:30 2008
@@ -1112,7 +1112,7 @@
          ",anyexact" => sub {
              my @list;
              foreach my $w (split(/,/, $v)) {
-                 if ($w eq "---" && $f !~ /milestone/) {
+                 if ($w eq "---" && $f =~ /resolution/) {
                      $w = "";
                  }
                  $q = $dbh->quote($w);

Modified: trunk/Bugzilla/Search/CVS/Entries
==============================================================================
--- trunk/Bugzilla/Search/CVS/Entries	(original)
+++ trunk/Bugzilla/Search/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -1,3 +1,3 @@
-/Quicksearch.pm/1.12.2.2/Sat Aug 11 20:17:21 2007//TBUGZILLA-3_0-BRANCH
 /Saved.pm/1.3.2.1/Sat Aug 11 20:17:21 2007//TBUGZILLA-3_0-BRANCH
+/Quicksearch.pm/1.12.2.3/Fri Apr 11 16:25:51 2008//TBUGZILLA-3_0-BRANCH
 D

Modified: trunk/Bugzilla/Search/Quicksearch.pm
==============================================================================
--- trunk/Bugzilla/Search/Quicksearch.pm	(original)
+++ trunk/Bugzilla/Search/Quicksearch.pm	Fri Apr 11 17:31:30 2008
@@ -267,7 +267,7 @@
                 foreach my $or_operand (split(/\|/, $qsword)) {
                     if ($or_operand =~ /^votes:([0-9]+)$/) {
                         # votes:xx ("at least xx votes")
-                        addChart('votes', 'greaterthan', $1, $negate);
+                        addChart('votes', 'greaterthan', $1 - 1, $negate);
                     }
                     elsif ($or_operand =~ /^([^:]+):([^:]+)$/) {
                         # generic field1,field2,field3:value1,value2 notation

Modified: trunk/Bugzilla/Template.pm
==============================================================================
--- trunk/Bugzilla/Template.pm	(original)
+++ trunk/Bugzilla/Template.pm	Fri Apr 11 17:31:30 2008
@@ -946,6 +946,9 @@
 
     # If anything created a Template object before now, clear it out.
     delete Bugzilla->request_cache->{template};
+    # This is the single variable used to precompile templates,
+    # which needs to be cleared as well.
+    delete Bugzilla->request_cache->{template_include_path_};
 }
 
 # Helper for precompile_templates

Modified: trunk/Bugzilla/Token.pm
==============================================================================
--- trunk/Bugzilla/Token.pm	(original)
+++ trunk/Bugzilla/Token.pm	Fri Apr 11 17:31:30 2008
@@ -34,6 +34,7 @@
 use Bugzilla::Error;
 use Bugzilla::Mailer;
 use Bugzilla::Util;
+use Bugzilla::User;
 
 use Date::Format;
 use Date::Parse;
@@ -80,20 +81,24 @@
     $template->process('account/email/request-new.txt.tmpl', $vars, \$message)
       || ThrowTemplateError($template->error());
 
+    # In 99% of cases, the user getting the confirmation email is the same one
+    # who made the request, and so it is reasonable to send the email in the same
+    # language used to view the "Create a New Account" page (we cannot use his
+    # user prefs as the user has no account yet!).
     MessageToMTA($message);
 }
 
 sub IssueEmailChangeToken {
-    my ($userid, $old_email, $new_email) = @_;
+    my ($user, $old_email, $new_email) = @_;
     my $email_suffix = Bugzilla->params->{'emailsuffix'};
 
-    my ($token, $token_ts) = _create_token($userid, 'emailold', $old_email . ":" . $new_email);
+    my ($token, $token_ts) = _create_token($user->id, 'emailold', $old_email . ":" . $new_email);
 
-    my $newtoken = _create_token($userid, 'emailnew', $old_email . ":" . $new_email);
+    my $newtoken = _create_token($user->id, 'emailnew', $old_email . ":" . $new_email);
 
     # Mail the user the token along with instructions for using it.
 
-    my $template = Bugzilla->template;
+    my $template = Bugzilla->template_inner($user->settings->{'lang'}->{'value'});
     my $vars = {};
 
     $vars->{'oldemailaddress'} = $old_email . $email_suffix;
@@ -118,38 +123,34 @@
     $template->process("account/email/change-new.txt.tmpl", $vars, \$message)
       || ThrowTemplateError($template->error());
 
+    Bugzilla->template_inner("");
     MessageToMTA($message);
 }
 
 # Generates a random token, adds it to the tokens table, and sends it
 # to the user with instructions for using it to change their password.
 sub IssuePasswordToken {
-    my $loginname = shift;
+    my $user = shift;
     my $dbh = Bugzilla->dbh;
-    my $template = Bugzilla->template;
-    my $vars = {};
 
-    # Retrieve the user's ID from the database.
-    trick_taint($loginname);
-    my ($userid, $too_soon) =
-        $dbh->selectrow_array('SELECT profiles.userid, tokens.issuedate
-                                 FROM profiles
-                            LEFT JOIN tokens
-                                   ON tokens.userid = profiles.userid
-                                  AND tokens.tokentype = ?
-                                  AND tokens.issuedate > NOW() - ' .
-                                      $dbh->sql_interval(10, 'MINUTE') . '
-                                WHERE ' . $dbh->sql_istrcmp('login_name', '?'),
-                                undef, ('password', $loginname));
+    my $too_soon =
+        $dbh->selectrow_array('SELECT 1 FROM tokens
+                                WHERE userid = ?
+                                  AND tokentype = ?
+                                  AND issuedate > NOW() - ' .
+                                      $dbh->sql_interval(10, 'MINUTE'),
+                                undef, ($user->id, 'password'));
 
     ThrowUserError('too_soon_for_new_token', {'type' => 'password'}) if $too_soon;
 
-    my ($token, $token_ts) = _create_token($userid, 'password', $::ENV{'REMOTE_ADDR'});
+    my ($token, $token_ts) = _create_token($user->id, 'password', $::ENV{'REMOTE_ADDR'});
 
     # Mail the user the token along with instructions for using it.
-    $vars->{'token'} = $token;
-    $vars->{'emailaddress'} = $loginname . Bugzilla->params->{'emailsuffix'};
+    my $template = Bugzilla->template_inner($user->settings->{'lang'}->{'value'});
+    my $vars = {};
 
+    $vars->{'token'} = $token;
+    $vars->{'emailaddress'} = $user->email;
     $vars->{'max_token_age'} = MAX_TOKEN_AGE;
     $vars->{'token_ts'} = $token_ts;
 
@@ -158,6 +159,7 @@
                                                                $vars, \$message)
       || ThrowTemplateError($template->error());
 
+    Bugzilla->template_inner("");
     MessageToMTA($message);
 }
 
@@ -207,31 +209,28 @@
     return $token;
 }
 
-# Cancels a previously issued token and notifies the system administrator.
+# Cancels a previously issued token and notifies the user.
 # This should only happen when the user accidentally makes a token request
 # or when a malicious hacker makes a token request on behalf of a user.
 sub Cancel {
     my ($token, $cancelaction, $vars) = @_;
     my $dbh = Bugzilla->dbh;
-    my $template = Bugzilla->template;
     $vars ||= {};
 
     # Get information about the token being canceled.
     trick_taint($token);
-    my ($issuedate, $tokentype, $eventdata, $loginname) =
+    my ($issuedate, $tokentype, $eventdata, $userid) =
         $dbh->selectrow_array('SELECT ' . $dbh->sql_date_format('issuedate') . ',
-                                      tokentype, eventdata, login_name
+                                      tokentype, eventdata, userid
                                  FROM tokens
-                            LEFT JOIN profiles
-                                   ON tokens.userid = profiles.userid
                                 WHERE token = ?',
                                 undef, $token);
 
-    # If we are cancelling the creation of a new user account, then there
+    # If we are canceling the creation of a new user account, then there
     # is no entry in the 'profiles' table.
-    $loginname ||= $eventdata;
-    $vars->{'emailaddress'} = $loginname . Bugzilla->params->{'emailsuffix'};
-    $vars->{'maintainer'} = Bugzilla->params->{'maintainer'};
+    my $user = new Bugzilla::User($userid);
+
+    $vars->{'emailaddress'} = $userid ? $user->email : $eventdata;
     $vars->{'remoteaddress'} = $::ENV{'REMOTE_ADDR'};
     $vars->{'token'} = $token;
     $vars->{'tokentype'} = $tokentype;
@@ -240,11 +239,13 @@
     $vars->{'cancelaction'} = $cancelaction;
 
     # Notify the user via email about the cancellation.
+    my $template = Bugzilla->template_inner($user->settings->{'lang'}->{'value'});
 
     my $message;
     $template->process("account/cancel-token.txt.tmpl", $vars, \$message)
       || ThrowTemplateError($template->error());
 
+    Bugzilla->template_inner("");
     MessageToMTA($message);
 
     # Delete the token from the database.
@@ -395,8 +396,8 @@
     use Bugzilla::Token;
 
     Bugzilla::Token::issue_new_user_account_token($login_name);
-    Bugzilla::Token::IssueEmailChangeToken($user_id, $old_email, $new_email);
-    Bugzilla::Token::IssuePasswordToken($login_name);
+    Bugzilla::Token::IssueEmailChangeToken($user, $old_email, $new_email);
+    Bugzilla::Token::IssuePasswordToken($user);
     Bugzilla::Token::DeletePasswordTokens($user_id, $reason);
     Bugzilla::Token::Cancel($token, $cancelaction, $vars);
 
@@ -426,26 +427,26 @@
  Returns:     Nothing. It throws an error if the same user made the same
               request in the last few minutes.
 
-=item C<sub IssueEmailChangeToken($user_id, $old_email, $new_email)>
+=item C<sub IssueEmailChangeToken($user, $old_email, $new_email)>
 
  Description: Sends two distinct tokens per email to the old and new email
               addresses to confirm the email address change for the given
-              user ID. These tokens remain valid for the next MAX_TOKEN_AGE days.
+              user. These tokens remain valid for the next MAX_TOKEN_AGE days.
 
- Params:      $user_id - The user ID of the user account requesting a new
-                         email address.
+ Params:      $user      - User object of the user requesting a new
+                           email address.
               $old_email - The current (old) email address of the user.
               $new_email - The new email address of the user.
 
  Returns:     Nothing.
 
-=item C<IssuePasswordToken($login_name)>
+=item C<IssuePasswordToken($user)>
 
- Description: Sends a token per email to the given login name. This token
+ Description: Sends a token per email to the given user. This token
               can be used to change the password (e.g. in case the user
               cannot remember his password and wishes to enter a new one).
 
- Params:      $login_name - The login name of the user requesting a new password.
+ Params:      $user - User object of the user requesting a new password.
 
  Returns:     Nothing. It throws an error if the same user made the same
               request in the last few minutes.

Modified: trunk/Bugzilla/Update.pm
==============================================================================
--- trunk/Bugzilla/Update.pm	(original)
+++ trunk/Bugzilla/Update.pm	Fri Apr 11 17:31:30 2008
@@ -42,8 +42,16 @@
         # but we failed because we cannot modify its timestamp?
         my $can_alter = 1;
         if (-e $local_file) {
-            # Try to alter its last modification time.
+            # Try to alter its last modification time. We first save the
+            # access and modification times of the file to restore them
+            # right after our test.
+            my $atime = (stat($local_file))[8];
+            my $mtime = (stat($local_file))[9];
             $can_alter = utime(undef, undef, $local_file);
+            # Restore the access and modification times to their
+            # original values, else LWP::UserAgent will never see the
+            # updated file on the server as newer than our local one.
+            utime($atime, $mtime, $local_file);
         }
         if ($can_alter) {
             my $error = _synchronize_data();
@@ -148,6 +156,8 @@
     else {
         $ua->env_proxy;
     }
+    # Download the file from the server if its modification time is newer
+    # than the local one.
     $ua->mirror(REMOTE_FILE, $local_file);
 
     # $ua->mirror() forces the modification time of the local XML file

Modified: trunk/Bugzilla/User.pm
==============================================================================
--- trunk/Bugzilla/User.pm	(original)
+++ trunk/Bugzilla/User.pm	Fri Apr 11 17:31:30 2008
@@ -579,21 +579,16 @@
 sub can_edit_product {
     my ($self, $prod_id) = @_;
     my $dbh = Bugzilla->dbh;
-    my $sth = $self->{sthCanEditProductId};
-    my $userid = $self->{id};
-    my $query = q{SELECT group_id FROM group_control_map 
-                   WHERE product_id =? 
-                     AND canedit != 0 };
-    if (%{$self->groups}) {
-        my $groups = join(',', values(%{$self->groups}));
-        $query .= qq{AND group_id NOT IN($groups)};
-    }
-    unless ($sth) { $sth = $dbh->prepare($query); }
-    $sth->execute($prod_id);
-    $self->{sthCanEditProductId} = $sth;
-    my $result = $sth->fetchrow_array();
-    
-    return (!defined($result));
+
+    my $has_external_groups =
+      $dbh->selectrow_array('SELECT 1
+                               FROM group_control_map
+                              WHERE product_id = ?
+                                AND canedit != 0
+                                AND group_id NOT IN(' . $self->groups_as_string . ')',
+                             undef, $prod_id);
+
+    return !$has_external_groups;
 }
 
 sub can_see_bug {
@@ -795,7 +790,7 @@
 
     ($self->in_group('editcomponents', $product->id)
        && $self->can_see_product($product->name))
-         || ThrowUserError('product_access_denied', {product => $product->name});
+         || ThrowUserError('product_admin_denied', {product => $product->name});
 
     # Return the validated product object.
     return $product;

Modified: trunk/Bugzilla/WebService/Bug.pm
==============================================================================
--- trunk/Bugzilla/WebService/Bug.pm	(original)
+++ trunk/Bugzilla/WebService/Bug.pm	Fri Apr 11 17:31:30 2008
@@ -116,11 +116,6 @@
         $field_values{$field_name} = $params->{$field}; 
     }
 
-    # Make sure all the required fields are in the hash.
-    foreach my $field (Bugzilla::Bug::REQUIRED_CREATE_FIELDS) {
-        $field_values{$field} = undef unless exists $field_values{$field};
-    }
-
     # WebService users can't set the creation date of a bug.
     delete $field_values{'creation_ts'};
 
@@ -438,8 +433,8 @@
 
 =item 104 (Invalid Field)
 
-One of the drop-down fields has an invalid value. The error message will
-have more detail.
+One of the drop-down fields has an invalid value, or a value entered in a
+text field is too long. The error message will have more detail.
 
 =item 105 (Invalid Component)
 
@@ -462,6 +457,15 @@
 
 =back
 
+=item B<History>
+
+=over
+
+=item Before B<3.0.4>, parameters marked as B<Defaulted> were actually
+B<Required>, due to a bug in Bugzilla.
+
+=back
+
 =back
 
 

Modified: trunk/Bugzilla/WebService/CVS/Entries
==============================================================================
--- trunk/Bugzilla/WebService/CVS/Entries	(original)
+++ trunk/Bugzilla/WebService/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -1,6 +1,6 @@
 /Bugzilla.pm/1.4/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
 /Product.pm/1.4/Sun Apr  8 13:11:07 2007//TBUGZILLA-3_0-BRANCH
-/Bug.pm/1.4.2.2/Sun Sep  2 09:52:04 2007//TBUGZILLA-3_0-BRANCH
-/Constants.pm/1.6.2.2/Tue Nov  6 20:18:14 2007//TBUGZILLA-3_0-BRANCH
 /User.pm/1.4.2.1/Tue Nov  6 20:18:14 2007//TBUGZILLA-3_0-BRANCH
+/Bug.pm/1.4.2.4/Fri Apr 11 16:25:51 2008//TBUGZILLA-3_0-BRANCH
+/Constants.pm/1.6.2.4/Fri Apr 11 16:25:51 2008//TBUGZILLA-3_0-BRANCH
 D

Modified: trunk/Bugzilla/WebService/Constants.pm
==============================================================================
--- trunk/Bugzilla/WebService/Constants.pm	(original)
+++ trunk/Bugzilla/WebService/Constants.pm	Fri Apr 11 17:31:30 2008
@@ -54,6 +54,7 @@
     invalid_bug_id_or_alias     => 100,
     invalid_bug_id_non_existent => 101,
     bug_access_denied           => 102,
+    bug_access_query            => 102,
     invalid_field_name          => 108,
     # These all mean "invalid alias"
     alias_not_defined        => 103,
@@ -63,6 +64,7 @@
     alias_has_comma_or_space => 103,
     # Misc. bug field errors
     illegal_field => 104,
+    freetext_too_long => 104,
     # Component errors
     require_component       => 105,
     component_name_too_long => 105,

Modified: trunk/CVS/Entries
==============================================================================
--- trunk/CVS/Entries	(original)
+++ trunk/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -8,8 +8,6 @@
 D/template////
 /.cvsignore/1.7/dummy timestamp from new-entry//TBUGZILLA-3_0-BRANCH
 /README/1.52/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
-/UPGRADING-pre-2.8/1.3/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
-/attachment.cgi/1.126/Sun Jan 21 15:43:15 2007//TBUGZILLA-3_0-BRANCH
 /bugzilla.dtd/1.15/Sun Jan  7 01:57:43 2007//TBUGZILLA-3_0-BRANCH
 /checksetup.pl/1.547/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /colchange.cgi/1.58/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
@@ -24,7 +22,6 @@
 /editkeywords.cgi/1.43/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /editmilestones.cgi/1.57/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /editsettings.cgi/1.9/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
-/editusers.cgi/1.141/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /editvalues.cgi/1.19/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /editversions.cgi/1.53/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /editwhines.cgi/1.20/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
@@ -32,11 +29,9 @@
 /importxml.pl/1.74.2.1/Sun Apr  8 13:11:06 2007//TBUGZILLA-3_0-BRANCH
 /index.cgi/1.23/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /long_list.cgi/1.47/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
-/mod_perl.pl/1.5/Sun Apr  8 13:11:06 2007//TBUGZILLA-3_0-BRANCH
 /page.cgi/1.19/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /productmenu.js/1.3/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /quips.cgi/1.37/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
-/relogin.cgi/1.39/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /report.cgi/1.39/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /reports.cgi/1.89/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /request.cgi/1.41/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
@@ -51,27 +46,32 @@
 /summarize_time.cgi/1.21/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /testagent.cgi/1.3/Sun Apr  8 13:11:06 2007//TBUGZILLA-3_0-BRANCH
 /testserver.pl/1.16/Sun Apr  8 13:11:06 2007//TBUGZILLA-3_0-BRANCH
-/token.cgi/1.48/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
-/whine.pl/1.32/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /xml.cgi/1.13/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /xmlrpc.cgi/1.2/Sun Apr  8 13:11:06 2007//TBUGZILLA-3_0-BRANCH
 /duplicates.cgi/1.59.2.1/Sat May 12 19:37:51 2007//TBUGZILLA-3_0-BRANCH
 /Bugzilla.pm/1.55.2.2/Sat Aug 11 20:17:19 2007//TBUGZILLA-3_0-BRANCH
 /chart.cgi/1.23.2.1/Sat Aug 11 20:17:19 2007//TBUGZILLA-3_0-BRANCH
 /editcomponents.cgi/1.80.2.1/Sat Aug 11 20:17:19 2007//TBUGZILLA-3_0-BRANCH
-/editproducts.cgi/1.132.2.2/Sat Aug 11 20:17:19 2007//TBUGZILLA-3_0-BRANCH
-/process_bug.cgi/1.351.2.6/Result of merge//TBUGZILLA-3_0-BRANCH
 /sanitycheck.cgi/1.127.2.2/Sat Aug 11 20:17:20 2007//TBUGZILLA-3_0-BRANCH
 /showdependencygraph.cgi/1.56.2.3/Result of merge//TBUGZILLA-3_0-BRANCH
-/userprefs.cgi/1.112.2.3/Sat Aug 11 20:17:20 2007//TBUGZILLA-3_0-BRANCH
 /votes.cgi/1.50.2.1/Sat Aug 11 20:17:20 2007//TBUGZILLA-3_0-BRANCH
-/whineatnews.pl/1.27.2.2/Sat Aug 11 20:17:20 2007//TBUGZILLA-3_0-BRANCH
 /UPGRADING/1.1/Sat Sep  1 19:01:43 2007//TBUGZILLA-3_0-BRANCH
 /collectstats.pl/1.58.2.3/Sun Sep  2 09:52:03 2007//TBUGZILLA-3_0-BRANCH
 /editparams.cgi/1.43.2.1/Sun Sep  2 09:52:03 2007//TBUGZILLA-3_0-BRANCH
 /QUICKSTART/1.6.4.2/Tue Nov  6 20:18:12 2007//TBUGZILLA-3_0-BRANCH
-/buglist.cgi/1.351.2.7/Tue Nov  6 20:18:12 2007//TBUGZILLA-3_0-BRANCH
 /config.cgi/1.24.2.1/Tue Nov  6 20:18:12 2007//TBUGZILLA-3_0-BRANCH
-/email_in.pl/1.5.2.3/Tue Nov  6 20:18:13 2007//TBUGZILLA-3_0-BRANCH
 /post_bug.cgi/1.183.2.2/Tue Nov  6 20:18:13 2007//TBUGZILLA-3_0-BRANCH
-/query.cgi/1.172.2.1/Result of merge//TBUGZILLA-3_0-BRANCH
+/UPGRADING-pre-2.8/1.3.14.1/Fri Apr 11 16:25:49 2008//TBUGZILLA-3_0-BRANCH
+/attachment.cgi/1.126.2.1/Fri Apr 11 16:25:49 2008//TBUGZILLA-3_0-BRANCH
+/buglist.cgi/1.351.2.8/Fri Apr 11 16:25:49 2008//TBUGZILLA-3_0-BRANCH
+/editproducts.cgi/1.132.2.3/Fri Apr 11 16:25:49 2008//TBUGZILLA-3_0-BRANCH
+/editusers.cgi/1.141.2.1/Fri Apr 11 16:25:49 2008//TBUGZILLA-3_0-BRANCH
+/email_in.pl/1.5.2.9/Fri Apr 11 16:25:49 2008//TBUGZILLA-3_0-BRANCH
+/mod_perl.pl/1.5.2.2/Fri Apr 11 16:25:49 2008//TBUGZILLA-3_0-BRANCH
+/process_bug.cgi/1.351.2.10/Result of merge+Fri Apr 11 16:25:50 2008//TBUGZILLA-3_0-BRANCH
+/query.cgi/1.172.2.3/Result of merge//TBUGZILLA-3_0-BRANCH
+/relogin.cgi/1.39.2.1/Fri Apr 11 16:25:50 2008//TBUGZILLA-3_0-BRANCH
+/token.cgi/1.48.2.1/Fri Apr 11 16:25:50 2008//TBUGZILLA-3_0-BRANCH
+/userprefs.cgi/1.112.2.4/Fri Apr 11 16:25:50 2008//TBUGZILLA-3_0-BRANCH
+/whine.pl/1.32.2.1/Fri Apr 11 16:25:50 2008//TBUGZILLA-3_0-BRANCH
+/whineatnews.pl/1.27.2.3/Fri Apr 11 16:25:50 2008//TBUGZILLA-3_0-BRANCH

Modified: trunk/UPGRADING-pre-2.8
==============================================================================
--- trunk/UPGRADING-pre-2.8	(original)
+++ trunk/UPGRADING-pre-2.8	Fri Apr 11 17:31:30 2008
@@ -4,6 +4,11 @@
 Upgrade instructions in The Bugzilla Guide, found with this distribution in
 docs/html, docs/txt, and docs/sgml.
 
+Please note that the period in our version numbers is a place separator, not
+a decimal point.  The 14 in version 2.14 is newer than the 8 in 2.8, for
+example.  You should only be using this file if you have a single digit
+after the period in the version 2.x Bugzilla you are upgrading from.
+
 For a complete list of what changes, use Bonsai
 (http://cvs-mirror.mozilla.org/webtools/bonsai/cvsqueryform.cgi) to
 query the CVS tree.  For example,

Modified: trunk/attachment.cgi
==============================================================================
--- trunk/attachment.cgi	(original)
+++ trunk/attachment.cgi	Fri Apr 11 17:31:30 2008
@@ -638,6 +638,7 @@
           # function call in Flag::notify. group_group_map is in here si
           # Bugzilla::User can flatten groups.
           'bugs WRITE', 'profiles READ', 'email_setting READ',
+          'setting READ', 'profile_setting READ',
           'cc READ', 'bug_group_map READ', 'user_group_map READ',
           'group_group_map READ', 'groups READ', 'group_control_map READ');
 

Modified: trunk/buglist.cgi
==============================================================================
--- trunk/buglist.cgi	(original)
+++ trunk/buglist.cgi	Fri Apr 11 17:31:30 2008
@@ -1132,7 +1132,7 @@
 $vars->{'currenttime'} = time();
 
 # The following variables are used when the user is making changes to multiple bugs.
-if ($dotweak) {
+if ($dotweak && scalar @bugs) {
     $vars->{'dotweak'} = 1;
     $vars->{'use_keywords'} = 1 if Bugzilla::Keyword::keyword_count();
 

Modified: trunk/contrib/CVS/Entries
==============================================================================
--- trunk/contrib/CVS/Entries	(original)
+++ trunk/contrib/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -9,9 +9,9 @@
 /recode.pl/1.4/Mon Jan  1 02:45:18 2007//TBUGZILLA-3_0-BRANCH
 /sendbugmail.pl/1.7/Mon Jan  1 00:11:02 2007//TBUGZILLA-3_0-BRANCH
 /sendunsentbugmail.pl/1.9/Mon Jan  1 00:11:02 2007//TBUGZILLA-3_0-BRANCH
-/syncLDAP.pl/1.9/Mon Jan  1 00:11:02 2007//TBUGZILLA-3_0-BRANCH
 /yp_nomail.sh/1.1/Mon Jan  1 00:11:02 2007//TBUGZILLA-3_0-BRANCH
 /bz_webservice_demo.pl/1.7.2.3/Sat Aug 11 20:17:21 2007//TBUGZILLA-3_0-BRANCH
 /bzdbcopy.pl/1.3.2.1/Result of merge//TBUGZILLA-3_0-BRANCH
 /README/1.10.14.2/Tue Nov  6 20:18:14 2007//TBUGZILLA-3_0-BRANCH
-/merge-users.pl/1.3.2.2/Tue Nov  6 20:18:14 2007//TBUGZILLA-3_0-BRANCH
+/merge-users.pl/1.3.2.3/Fri Apr 11 16:25:51 2008//TBUGZILLA-3_0-BRANCH
+/syncLDAP.pl/1.9.2.1/Fri Apr 11 16:25:51 2008//TBUGZILLA-3_0-BRANCH

Modified: trunk/contrib/merge-users.pl
==============================================================================
--- trunk/contrib/merge-users.pl	(original)
+++ trunk/contrib/merge-users.pl	Fri Apr 11 17:31:30 2008
@@ -49,6 +49,7 @@
 use Bugzilla;
 use Bugzilla::Constants;
 use Bugzilla::Util;
+use Bugzilla::User;
 
 use Getopt::Long;
 use Pod::Usage;
@@ -233,4 +234,7 @@
 # Unlock tables
 $dbh->bz_unlock_tables();
 
+my $user = new Bugzilla::User($new_id);
+$user->derive_regexp_groups();
+
 print "Done.\n";

Modified: trunk/contrib/syncLDAP.pl
==============================================================================
--- trunk/contrib/syncLDAP.pl	(original)
+++ trunk/contrib/syncLDAP.pl	Fri Apr 11 17:31:30 2008
@@ -276,7 +276,7 @@
         Bugzilla::User->create({
             login_name => $key, 
             realname   => @$value{'realname'},
-            password   => '*'});
+            cryptpassword   => '*'});
       }
       print "done!\n" unless $quiet;
    }

Modified: trunk/docs/xml/Bugzilla-Guide.xml
==============================================================================
--- trunk/docs/xml/Bugzilla-Guide.xml	(original)
+++ trunk/docs/xml/Bugzilla-Guide.xml	Fri Apr 11 17:31:30 2008
@@ -34,10 +34,10 @@
      For a devel release, simple bump bz-ver and bz-date
 -->
 
-<!ENTITY bz-ver "3.0.2">
+<!ENTITY bz-ver "3.0.3">
 <!ENTITY bz-nextver "3.2">
-<!ENTITY bz-date "2007-09-18">
-<!ENTITY current-year "2007">
+<!ENTITY bz-date "2008-01-08">
+<!ENTITY current-year "2008">
 
 <!ENTITY landfillbase "http://landfill.bugzilla.org/bugzilla-3.0-branch/";>
 <!ENTITY bz "http://www.bugzilla.org/";>

Modified: trunk/docs/xml/CVS/Entries
==============================================================================
--- trunk/docs/xml/CVS/Entries	(original)
+++ trunk/docs/xml/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -1,20 +1,20 @@
 /.cvsignore/1.1/dummy timestamp from new-entry//TBUGZILLA-3_0-BRANCH
-/conventions.xml/1.11/Mon Jan  1 00:11:02 2007//TBUGZILLA-3_0-BRANCH
 /gfdl.xml/1.11/Mon Jan  1 00:11:02 2007//TBUGZILLA-3_0-BRANCH
 /index.xml/1.6/Mon Jan  1 00:11:02 2007//TBUGZILLA-3_0-BRANCH
 /integration.xml/1.13.12.1/Sun Apr  8 13:11:07 2007//TBUGZILLA-3_0-BRANCH
-/modules.xml/1.12/Sun Apr  8 13:11:07 2007//TBUGZILLA-3_0-BRANCH
 /requiredsoftware.xml/1.7/Mon Jan  1 00:11:02 2007//TBUGZILLA-3_0-BRANCH
 /troubleshooting.xml/1.12/Mon Jan  1 00:11:02 2007//TBUGZILLA-3_0-BRANCH
 /about.xml/1.24.2.3/Sat Aug 11 20:17:22 2007//TBUGZILLA-3_0-BRANCH
-/customization.xml/1.37.2.3/Sat Aug 11 20:17:22 2007//TBUGZILLA-3_0-BRANCH
 /introduction.xml/1.5.14.1/Sat Aug 11 20:17:22 2007//TBUGZILLA-3_0-BRANCH
 /patches.xml/1.24.2.1/Sat Aug 11 20:17:22 2007//TBUGZILLA-3_0-BRANCH
-/using.xml/1.64.2.6/Sat Aug 11 20:17:22 2007//TBUGZILLA-3_0-BRANCH
-/Bugzilla-Guide.xml/1.71.2.4/Tue Nov  6 20:18:14 2007//TBUGZILLA-3_0-BRANCH
-/administration.xml/1.70.2.5/Tue Nov  6 20:18:14 2007//TBUGZILLA-3_0-BRANCH
-/faq.xml/1.46.2.6/Tue Nov  6 20:18:15 2007//TBUGZILLA-3_0-BRANCH
 /glossary.xml/1.23.2.2/Tue Nov  6 20:18:15 2007//TBUGZILLA-3_0-BRANCH
-/installation.xml/1.136.2.6/Tue Nov  6 20:18:15 2007//TBUGZILLA-3_0-BRANCH
 /security.xml/1.16.2.1/Tue Nov  6 20:18:15 2007//TBUGZILLA-3_0-BRANCH
+/Bugzilla-Guide.xml/1.71.2.5/Fri Apr 11 16:25:51 2008//TBUGZILLA-3_0-BRANCH
+/administration.xml/1.70.2.12/Fri Apr 11 16:25:52 2008//TBUGZILLA-3_0-BRANCH
+/conventions.xml/1.11.2.1/Fri Apr 11 16:25:52 2008//TBUGZILLA-3_0-BRANCH
+/customization.xml/1.37.2.4/Fri Apr 11 16:25:52 2008//TBUGZILLA-3_0-BRANCH
+/faq.xml/1.46.2.7/Fri Apr 11 16:25:52 2008//TBUGZILLA-3_0-BRANCH
+/installation.xml/1.136.2.12/Fri Apr 11 16:25:52 2008//TBUGZILLA-3_0-BRANCH
+/modules.xml/1.12.2.1/Fri Apr 11 16:25:52 2008//TBUGZILLA-3_0-BRANCH
+/using.xml/1.64.2.12/Fri Apr 11 16:25:52 2008//TBUGZILLA-3_0-BRANCH
 D

Modified: trunk/docs/xml/administration.xml
==============================================================================
--- trunk/docs/xml/administration.xml	(original)
+++ trunk/docs/xml/administration.xml	Fri Apr 11 17:31:30 2008
@@ -7,322 +7,862 @@
 
     <para>
       Bugzilla is configured by changing various parameters, accessed
-      from the "Edit parameters" link in the page footer. Here are
-      some of the key parameters on that page. You should run down this
-      list and set them appropriately after installing Bugzilla.
+      from the "Parameters" link in the page footer.  
+      The parameters are divided into several categories,
+      accessed via the menu on the left. Following is a description of the 
+      different categories and important parameters within those categories. 
     </para>
 
-    <indexterm>
-      <primary>checklist</primary>
-    </indexterm>
+      <section id="param-requiredsettings">
+        <title>Required Settings</title>
 
-    <variablelist>
-      <varlistentry>
-        <term>
-          maintainer
-        </term>
-        <listitem>
-          <para> 
-            The maintainer parameter is the email address of the person 
-            responsible for maintaining this Bugzilla installation.
-            The address need not be that of a valid Bugzilla account.
-          </para>
-        </listitem>
-      </varlistentry>
+        <para>
+          The core required parameters for any Bugzilla installation are set
+          here. These parameters must be set before a new Bugzilla installation
+          can be used. Administrators should review this list before 
+          deploying a new Bugzilla installation.
+        </para>
 
-      <varlistentry>
-        <term>
-          urlbase
-        </term>
-        <listitem>
-          <para>
-            This parameter defines the fully qualified domain name and web 
-            server path to your Bugzilla installation.
-          </para>
+        <indexterm>
+          <primary>checklist</primary>
+        </indexterm>
 
-          <para>
-            For example, if your Bugzilla query page is
-            <filename>http://www.foo.com/bugzilla/query.cgi</filename>, 
-            set your <quote>urlbase</quote>
-            to <filename>http://www.foo.com/bugzilla/</filename>.
-          </para>
-        </listitem>
-      </varlistentry>
+        <variablelist>
 
-      <varlistentry>
-        <term>
-          makeproductgroups
-        </term>
-        <listitem>
-          <para>
-            This dictates whether or not to automatically create groups
-            when new products are created.
-          </para>
-        </listitem>
-      </varlistentry>
+          <varlistentry>
+            <term>
+              maintainer
+            </term>
+            <listitem>
+              <para> 
+              Email address of the person 
+              responsible for maintaining this Bugzilla installation.
+              The address need not be that of a valid Bugzilla account.
+            </para>
+            </listitem>
+          </varlistentry>
 
-      <varlistentry>
-        <term>
-          useentrygroupdefault
-        </term>
-        <listitem>
-          <para>
-            Bugzilla products can have a group associated with them, so that
-            certain users can only see bugs in certain products. When this 
-            parameter is set to <quote>on</quote>, this 
-            causes the initial group controls on newly created products 
-            to place all newly-created bugs in the group 
-            having the same name as the product immediately.
-            After a product is initially created, the group controls
-            can be further adjusted without interference by 
-            this mechanism.
-          </para>
-        </listitem>
-      </varlistentry>
+          <varlistentry>
+            <term>
+              urlbase
+            </term>
+            <listitem>
+              <para>
+                Defines the fully qualified domain name and web 
+                server path to this Bugzilla installation.
+              </para>
+              <para>
+                For example, if the Bugzilla query page is
+                <filename>http://www.foo.com/bugzilla/query.cgi</filename>, 
+                the <quote>urlbase</quote> should be set
+                to <filename>http://www.foo.com/bugzilla/</filename>.
+              </para>
+            </listitem>
+          </varlistentry>
 
-      <varlistentry>
-        <term>
-          mail_delivery_method
-        </term>
-        <listitem>
+          <varlistentry>
+            <term>
+              docs_urlbase
+            </term>
+            <listitem>
+              <para>
+                Defines path to the Bugzilla documentation. This can be a fully
+                qualified domain name, or a path relative to "urlbase".
+              </para>
+              <para>
+                For example, if the "Bugzilla Configuration" page 
+                of the documentation is
+                <filename>http://www.foo.com/bugzilla/docs/html/parameters.html</filename>, 
+                set the <quote>docs_urlbase</quote>
+                to <filename>http://www.foo.com/bugzilla/docs/html/</filename>.
+              </para>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              sslbase
+            </term>
+            <listitem>
+              <para>
+                Defines the fully qualified domain name and web 
+                server path for HTTPS (SSL) connections to this Bugzilla installation.
+              </para>
+              <para>
+                For example, if the Bugzilla main page is
+                <filename>https://www.foo.com/bugzilla/index.cgi</filename>, 
+                the <quote>sslbase</quote> should be set
+                to <filename>https://www.foo.com/bugzilla/</filename>.
+              </para>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              ssl
+            </term>
+            <listitem>
+              <para>
+                Determines when Bugzilla will force HTTPS (SSL) connections, using
+                the URL defined in <command>sslbase</command>. 
+                Options include "always", "never", and "authenticated sessions". 
+              </para>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              cookiedomain
+            </term>
+            <listitem>
+              <para>
+               Defines the domain for Bugzilla cookies. This is typically left blank.
+               If there are multiple hostnames that point to the same webserver, which
+               require the same cookie, then this parameter can be utilized. For
+               example, If your website is at 
+               <filename>https://www.foo.com/</filename>, setting this to 
+               <filename>.foo.com/</filename> will also allow 
+               <filename>bar.foo.com/</filename> to access Bugzilla cookies.
+              </para>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              cookiepath
+            </term>
+            <listitem>
+              <para>
+                Defines a path, relative to the web server root, that Bugzilla
+                cookies will be restricted to. For example, if the 
+                <command>urlbase</command> is set to
+                <filename>http://www.foo.com/bugzilla/</filename>, the 
+                <command>cookiepath</command> should be set to 
+                <filename>/bugzilla/</filename>. Setting it to "/" will allow all sites 
+                served by this web server or virtual host to read Bugzilla cookies.
+              </para>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              timezone
+            </term>
+            <listitem>
+              <para>
+                Timezone of server. The timezone is displayed with timestamps. If 
+                this parameter is left blank, the timezone is not displayed.
+              </para>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              utf8
+            </term>
+            <listitem>
+              <para>
+               Determines whether to use UTF-8 (Unicode) encoding for all text in 
+               Bugzilla. New installations should set this to true to avoid character 
+               encoding problems. Existing databases should set this to true only 
+               after the data has been converted from existing legacy character 
+               encoding to UTF-8, using the 
+               <filename>contrib/recode.pl</filename> script.
+              </para>
+              <note>
+                <para>
+                  If you turn this parameter from "off" to "on", you must re-run 
+                  <filename>checksetup.pl</filename> immediately afterward.
+                </para>
+              </note>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              shutdownhtml
+            </term>
+            <listitem>
+              <para>
+                If there is any text in this field, this Bugzilla installation will
+                be completely disabled and this text will appear instead of all
+                Bugzilla pages for all users, including Admins. Used in the event 
+                of site maintenance or outage situations. 
+              </para>
+              <note>
+                <para>
+                  Although regular log-in capability is disabled while 
+                  <command>shutdownhtml</command>
+                  is enabled, safeguards are in place to protect the unfortunate 
+                  admin who loses connection to Bugzilla. Should this happen to you,
+                  go directly to the <filename>editparams.cgi</filename> (by typing
+                  the URL in manually, if necessary). Doing this will prompt you to
+                  log in, and your name/password will be accepted here (but nowhere
+                  else). 
+                </para>
+              </note>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              announcehtml
+            </term>
+            <listitem>
+              <para>
+                Any text in this field will be displayed at the top of every HTML
+                page in this Bugzilla installation. The text is not wrapped in any
+                tags. For best results, wrap the text in a <quote>&lt;div&gt;</quote>
+                tag. Any style attributes from the CSS can be applied. For example,
+                to make the text green inside of a red box, add <quote>id=message</quote>
+                to the <quote>&lt;div&gt;</quote> tag.
+              </para>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              proxy_url
+            </term>
+            <listitem>
+              <para>
+                If this Bugzilla installation is behind a proxy, enter the proxy 
+                information here to enable Bugzilla to access the Internet. Bugzilla
+                requires Internet access to utilize the 
+                <command>upgrade_notification</command> parameter (below). If the 
+                proxy requires authentication, use the syntax:
+                <filename>http://user:pass proxy_url/</filename>.
+              </para>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              upgrade_notification
+            </term>
+            <listitem>
+              <para>
+                Enable or disable a notification on the homepage of this Bugzilla
+                installation when a newer version of Bugzilla is available. This
+                notification is only visible to administrators. Choose "disabled",
+                to turn off the notification. Otherwise, choose which version of
+                Bugzilla you want to be notified about: "development_snapshot" is the
+                latest release on the trunk; "latest_stable_release" is the most 
+                recent release available on the most recent stable branch; 
+                "stable_branch_release" the most recent release on the branch 
+                this installation is based on.
+              </para>
+            </listitem>
+          </varlistentry>
+
+        </variablelist>
+
+        </section>
+
+        <section id="param-admin-policies">
+          <title>Administrative Policies</title>
+        <para>
+        This page contains parameters for basic administrative functions.
+        Options include whether to allow the deletion of bugs and users, whether
+        to allow users to change their email address, and whether to allow
+        user watching (one user receiving all notifications of a selected
+        other user). 
+        </para>
+
+        <variablelist>
+
+          <varlistentry>
+            <term>
+              supportwatchers
+            </term>
+            <listitem>
+              <para>
+                Turning on this option allows users to ask to receive copies 
+                of bug mail sent to another user.  Watching a user with
+                different group permissions is not a way to 'get around' the
+                system; copied emails are still subject to the normal groupset
+                permissions of a bug, and <quote>watchers</quote> will only be 
+                copied on emails from bugs they would normally be allowed to view. 
+              </para> 
+            </listitem>
+          </varlistentry>
+
+        </variablelist>
+
+        </section>
+
+        <section id="param-user-authentication">
+          <title>User Authentication</title>
           <para>
-            This is used to specify how email is sent, or if it is sent at 
-            all.  There are several options included for different MTAs, 
-            along with two additional options that disable email sending.  
-            "testfile" does not send mail, but instead saves it in 
-            <filename>data/mailer.testfile</filename> for later review.  
-            "none" disables email sending entirely.
-          </para>
-        </listitem>
-      </varlistentry>
+            This page contains the settings that control how this Bugzilla
+            installation will do its authentication. Choose what authentication
+            mechanism to use (the Bugzilla database, or an external source such
+            as LDAP), and set basic behavioral parameters. For example, choose
+            whether to require users to login to browse bugs, the management
+            of authentication cookies, and the regular expression used to
+            validate email addresses. Some parameters are highlighted below.
+          </para>
+
+        <variablelist>
+
+          <varlistentry>
+            <term>
+              emailregexp
+            </term>
+            <listitem>
+              <para>
+                Defines the regular expression used to validate email addresses
+                used for login names. The default attempts to match fully
+                qualified email addresses (i.e. 'user example com'). Some
+                Bugzilla installations allow only local user names (i.e 'user' 
+                instead of 'user example com'). In that case, the 
+                <command>emailsuffix</command> parameter should be used to define
+                the email domain.    
+              </para>
+            </listitem>
+          </varlistentry>
 
-      <varlistentry>
-        <term>
-          shadowdb
-        </term>
-        <listitem>
+          <varlistentry>
+            <term>
+              emailsuffix
+            </term>
+            <listitem>
+              <para>
+                This string is appended to login names when actually sending 
+                email to a user. For example,
+                If <command>emailregexp</command> has been set to allow
+                local usernames,
+                then this parameter would contain the email domain for all users
+                (i.e. '@example.com').   
+              </para>
+            </listitem>
+          </varlistentry>
+
+        </variablelist>
+
+        </section>
+
+        <section id="param-attachments">
+          <title>Attachments</title>
           <para>
-            You run into an interesting problem when Bugzilla reaches a
-            high level of continuous activity. MySQL supports only table-level
-            write locking. What this means is that if someone needs to make a
-            change to a bug, they will lock the entire table until the operation
-            is complete. Locking for write also blocks reads until the write is
-            complete. Note that more recent versions of mysql support row level
-            locking using different table types. These types are slower than the
-            standard type, and Bugzilla does not yet take advantage of features
-            such as transactions which would justify this speed decrease. The
-            Bugzilla team are, however, happy to hear about any experiences with
-            row level locking and Bugzilla.
+            This page allows for setting restrictions and other parameters
+            regarding attachments to bugs. For example, control size limitations
+            and whether to allow pointing to external files via a URI.
           </para>
+        </section>
 
+        <section id="param-bug-change-policies">
+          <title>Bug Change Policies</title>
           <para>
-            The <quote>shadowdb</quote> parameter was designed to get around
-            this limitation. While only a single user is allowed to write to
-            a table at a time, reads can continue unimpeded on a read-only
-            shadow copy of the database. Although your database size will
-            double, a shadow database can cause an enormous performance
-            improvement when implemented on extremely high-traffic Bugzilla
-            databases.
+            Set policy on default behavior for bug change events. For example,
+            choose whether to allow bug reporters to set the priority or
+            target milestone. Also allows for configuration of what changes
+            should require the user to make a comment, described below.    
           </para>
-        
+
+        <variablelist>
+
+          <varlistentry>
+            <term>
+              commenton*
+            </term>
+            <listitem>
+              <para>
+                All these fields allow you to dictate what changes can pass
+                without comment, and which must have a comment from the
+                person who changed them.  Often, administrators will allow
+                users to add themselves to the CC list, accept bugs, or
+                change the Status Whiteboard without adding a comment as to
+                their reasons for the change, yet require that most other
+                changes come with an explanation.
+              </para>
+
+              <para>
+                Set the "commenton" options according to your site policy. It
+                is a wise idea to require comments when users resolve, reassign, or
+                reopen bugs at the very least. 
+              </para>
+
+              <note>
+                <para>
+                  It is generally far better to require a developer comment
+                  when resolving bugs than not. Few things are more annoying to bug
+                  database users than having a developer mark a bug "fixed" without
+                  any comment as to what the fix was (or even that it was truly
+                  fixed!)
+                </para>
+              </note>
+            </listitem>
+          </varlistentry>
+          <varlistentry>
+            <term>
+              noresolveonopenblockers
+            </term>
+            <listitem>
+              <para>
+                This option will prevent users from resolving bugs as FIXED if
+                they have unresolved dependencies. Only the FIXED resolution
+                is affected. Users will be still able to resolve bugs to
+                resolutions other than FIXED if they have unresolved dependent
+                bugs.
+              </para>
+            </listitem>
+          </varlistentry>
+
+        </variablelist>
+
+        </section>
+
+        <section id="param-bugfields">
+          <title>Bug Fields</title>
           <para>
-            As a guide, on reasonably old hardware, mozilla.org began needing 
-            <quote>shadowdb</quote> when they reached around 40,000 Bugzilla
-            users with several hundred Bugzilla bug changes and comments per day.
+            The parameters in this section determine the default settings of
+            several Bugzilla fields for new bugs, and also control whether
+            certain fields are used.
           </para>
 
+        <variablelist>
+
+          <varlistentry>    
+            <term>
+              useqacontact
+            </term>
+            <listitem>
+              <para>
+                This allows you to define an email address for each component, 
+                in addition to that of the default assignee, who will be sent
+                carbon copies of incoming bugs.
+              </para>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              usestatuswhiteboard
+            </term>
+            <listitem>
+              <para>
+                This defines whether you wish to have a free-form, overwritable field
+                associated with each bug. The advantage of the Status Whiteboard is
+                that it can be deleted or modified with ease, and provides an
+                easily-searchable field for indexing some bugs that have some trait
+                in common.         
+              </para>
+            </listitem>
+          </varlistentry>
+
+        </variablelist>
+
+        </section>
+
+        <section id="param-bugmoving">
+          <title>Bug Moving</title>
           <para>
-            The value of the parameter defines the name of the shadow bug
-            database. You will need to set the host and port settings from
-            the params page, and set up replication in your database server
-            so that updates reach this readonly mirror. Consult your database
-            documentation for more detail.
+            This page controls whether this Bugzilla installation allows certain
+            users to move bugs to an external database. If bug moving is enabled,
+            there are a number of parameters that control bug moving behaviors. 
+            For example, choose which users are allowed to move bugs, the location
+            of the external database, and the default product and component that
+            bugs moved <emphasis>from</emphasis> other bug databases to this 
+            Bugzilla installation are assigned to. 
           </para>
-        </listitem>
-      </varlistentry>
 
-      <varlistentry>
-        <term>
-          shutdownhtml
-        </term>
-        <listitem>
+        </section>
+
+        <section id="param-dependency-graphs">
+          <title>Dependency Graphs</title>
           <para>
-            If you need to shut down Bugzilla to perform administration, enter
-            some descriptive text (with embedded HTML codes, if you'd like)
-            into this box. Anyone who tries to use Bugzilla (including admins)
-            will receive a page displaying this text. Users can neither log in
-            nor log out while shutdownhtml is enabled.
+            This page has one parameter that sets the location of a Web Dot
+            server, or of the Web Dot binary on the local system, that is used
+            to generate dependency graphs. Web Dot is a CGI program that creates
+            images from <filename>.dot</filename> graphic description files. If
+            no Web Dot server or binary is specified, then dependency graphs will
+            be disabled.
           </para>
+        </section>
 
-          <note>
+        <section id="param-group-security">
+          <title>Group Security</title>
             <para>
-              Although regular log-in capability is disabled while 'shutdownhtml'
-              is enabled, safeguards are in place to protect the unfortunate 
-              admin who loses connection to Bugzilla. Should this happen to you,
-              go directly to the <filename>editparams.cgi</filename> (by typing
-              the URL in manually, if necessary). Doing this will prompt you to
-              log in, and your name/password will be accepted here (but nowhere
-              else). 
+              Bugzilla allows for the creation of different groups, with the
+              ability to restrict the visibility of bugs in a group to a set of 
+              specific users. Specific products can also be associated with
+              groups, and users restricted to only see products in their groups.
+              Several parameters are described in more detail below. Most of the
+              configuration of groups and their relationship to products is done
+              on the "Groups" and "Product" pages of the "Administration" area.
+              The options on this page control global default behavior. 
+              For more information on Groups and Group Security, see
+              <xref linkend="groups"/> 
             </para>
-          </note>
-        </listitem>
-      </varlistentry>
 
-      <varlistentry>
-        <term>
-          movebugs
-        </term>
-        <listitem>
+        <variablelist>
+
+          <varlistentry>
+            <term>
+              makeproductgroups
+            </term>
+            <listitem>
+              <para>
+                Determines whether or not to automatically create groups
+                when new products are created. If this is on, the groups will be
+                used for querying bugs.
+              </para>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              useentrygroupdefault
+            </term>
+            <listitem>
+              <para>
+                Bugzilla products can have a group associated with them, so that
+                certain users can only see bugs in certain products. When this 
+                parameter is set to <quote>on</quote>, this 
+                causes the initial group controls on newly created products 
+                to place all newly-created bugs in the group 
+                having the same name as the product immediately.
+                After a product is initially created, the group controls
+                can be further adjusted without interference by 
+                this mechanism.
+              </para>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              usevisibilitygroups
+            </term>
+            <listitem>
+              <para>
+                If selected, user visibility will be restricted to members of
+                groups, as selected in the group configuration settings. 
+                Each user-defined group can be allowed to see members of selected
+                other groups. 
+                For details on configuring groups (including the visibility 
+                restrictions) see <xref linkend="edit-groups"/>. 
+              </para>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              querysharegroup
+            </term>
+            <listitem>
+              <para>
+                The name of the group of users who are allowed to share saved
+                searches with one another. For more information on using 
+                saved searches, see <xref linkend="savedsearches"/>.
+              </para>
+            </listitem>
+          </varlistentry>
+
+        </variablelist>
+    
+        </section>
+
+        <section id="param-localization">
+          <title>Localization</title>
+
           <para>
-            This option is an undocumented feature to allow moving bugs
-            between separate Bugzilla installations.  You will need to understand
-            the source code in order to use this feature.  Please consult
-            <filename>movebugs.pl</filename> in your Bugzilla source tree for
-            further documentation, such as it is.
+            This section allows for setting which language is used by default
+            for this Bugzilla installation. The "languages" parameter can also
+            be used to determine which languages this Bugzilla installation
+            supports. Note that any language listed here must have its
+            corresponding language pack installed.
           </para>
-        </listitem>
-      </varlistentry>
 
-      <varlistentry>
-        <term>
-          useqacontact
-        </term>
-        <listitem>
-          <para>
-            This allows you to define an email address for each component, 
-            in addition to that of the default assignee, who will be sent
-            carbon copies of incoming bugs.
+        </section>
+
+        <section id="bzldap">
+          <title>LDAP Authentication</title>
+
+          <para>LDAP authentication is a module for Bugzilla's plugin 
+          authentication architecture. This page contains all the parameters
+          necessary to configure Bugzilla for use with LDAP authentication.
           </para>
-        </listitem>
-      </varlistentry>
 
-      <varlistentry>
-        <term>
-          globalwatcher
-        </term>
-        <listitem>
           <para>
-            This allows to define specific users that will
-            receive notification each time a new bug in entered, or when
-            an existing bug changes, according to the normal groupset
-            permissions. It may be useful for sending notifications to a
-            mailing-list, for instance.
-          </para>
-        </listitem>
-      </varlistentry>
+          The existing authentication
+          scheme for Bugzilla uses email addresses as the primary user ID, and a
+          password to authenticate that user. All places within Bugzilla that
+          require a user ID (e.g assigning a bug) use the email
+          address. The LDAP authentication builds on top of this scheme, rather
+          than replacing it. The initial log-in is done with a username and
+          password for the LDAP directory. Bugzilla tries to bind to LDAP using
+          those credentials and, if successful, tries to map this account to a
+          Bugzilla account. If an LDAP mail attribute is defined, the value of this
+          attribute is used, otherwise the "emailsuffix" parameter is appended to LDAP
+          username to form a full email address. If an account for this address
+          already exists in the Bugzilla installation, it will log in to that account.
+          If no account for that email address exists, one is created at the time
+          of login. (In this case, Bugzilla will attempt to use the "displayName"
+          or "cn" attribute to determine the user's full name.) After
+          authentication, all other user-related tasks are still handled by email
+          address, not LDAP username. For example, bugs are still assigned by
+          email address and users are still queried by email address.
+          </para>
+
+          <caution>
+            <para>Because the Bugzilla account is not created until the first time
+            a user logs in, a user who has not yet logged is unknown to Bugzilla.
+            This means they cannot be used as an assignee or QA contact (default or
+            otherwise), added to any CC list, or any other such operation. One
+            possible workaround is the <filename>bugzilla_ldapsync.rb</filename>
+            script in the
+            <glossterm linkend="gloss-contrib">
+            <filename class="directory">contrib</filename></glossterm> 
+            directory. Another possible solution is fixing
+            <ulink url="https://bugzilla.mozilla.org/show_bug.cgi?id=201069";>bug
+            201069</ulink>.
+            </para>
+          </caution>
 
-      <varlistentry>
-        <term>
-          usestatuswhiteboard
-        </term>
-        <listitem>
+          <para>Parameters required to use LDAP Authentication:</para>
+
+          <variablelist>
+            <varlistentry id="param-user_verify_class_for_ldap">
+              <term>user_verify_class</term>
+              <listitem>
+                <para>If you want to list <quote>LDAP</quote> here,
+                make sure to have set up the other parameters listed below.
+                Unless you have other (working) authentication methods listed as
+                well, you may otherwise not be able to log back in to Bugzilla once
+                you log out.
+                If this happens to you, you will need to manually edit
+                <filename>data/params</filename> and set user_verify_class to
+                <quote>DB</quote>.
+                </para>
+              </listitem>
+            </varlistentry>
+    
+            <varlistentry id="param-LDAPserver">
+              <term>LDAPserver</term>
+              <listitem>
+                <para>This parameter should be set to the name (and optionally the
+                port) of your LDAP server. If no port is specified, it assumes
+                the default LDAP port of 389.
+                </para>
+                <para>Ex. <quote>ldap.company.com</quote>
+                 or <quote>ldap.company.com:3268</quote>
+                </para>
+                <para>You can also specify a LDAP URI, so as to use other
+                protocols, such as LDAPS or LDAPI. If port was not specified in
+                the URI, the default is either 389 or 636 for 'LDAP' and 'LDAPS'
+                schemes respectively.
+                </para>
+                <para>Ex. <quote>ldap://ldap.company.com</quote>,
+                <quote>ldaps://ldap.company.com</quote> or
+                <quote>ldapi://%2fvar%2flib%2fldap_sock</quote>
+                </para>
+               </listitem>
+             </varlistentry>
+    
+             <varlistentry id="param-LDAPbinddn">
+               <term>LDAPbinddn [Optional]</term>
+               <listitem>
+                 <para>Some LDAP servers will not allow an anonymous bind to search
+                 the directory. If this is the case with your configuration you
+                 should set the LDAPbinddn parameter to the user account Bugzilla
+                 should use instead of the anonymous bind.
+                 </para>
+                 <para>Ex. <quote>cn=default,cn=user:password</quote></para>
+               </listitem>
+             </varlistentry>
+    
+             <varlistentry id="param-LDAPBaseDN">
+               <term>LDAPBaseDN</term>
+               <listitem>
+                 <para>The LDAPBaseDN parameter should be set to the location in
+                 your LDAP tree that you would like to search for email addresses.
+                 Your uids should be unique under the DN specified here.
+                 </para>
+                 <para>Ex. <quote>ou=People,o=Company</quote></para>
+               </listitem>
+             </varlistentry>
+    
+             <varlistentry id="param-LDAPuidattribute">
+               <term>LDAPuidattribute</term>
+               <listitem>
+                 <para>The LDAPuidattribute parameter should be set to the attribute
+                 which contains the unique UID of your users. The value retrieved
+                 from this attribute will be used when attempting to bind as the
+                 user to confirm their password.
+                 </para>
+                 <para>Ex. <quote>uid</quote></para>
+               </listitem>
+             </varlistentry>
+
+             <varlistentry id="param-LDAPmailattribute">
+               <term>LDAPmailattribute</term>
+               <listitem>
+                 <para>The LDAPmailattribute parameter should be the name of the
+                 attribute which contains the email address your users will enter
+                 into the Bugzilla login boxes.
+                 </para>
+                 <para>Ex. <quote>mail</quote></para>
+               </listitem>
+              </varlistentry>
+          </variablelist>
+
+        </section>
+    
+        <section id="param-email">
+          <title>Email</title>
           <para>
-            This defines whether you wish to have a free-form, overwritable field
-            associated with each bug. The advantage of the Status Whiteboard is
-            that it can be deleted or modified with ease, and provides an
-            easily-searchable field for indexing some bugs that have some trait
-            in common.         
+            This page contains all of the parameters for configuring how
+            Bugzilla deals with the email notifications it sends. See below
+            for a summary of important options. 
           </para>
-        </listitem>
-      </varlistentry>
 
-      <varlistentry>
-        <term>
-          whinedays
-        </term>
-        <listitem>
+        <variablelist>
+
+          <varlistentry>
+            <term>
+              mail_delivery_method
+            </term>
+            <listitem>
+              <para>
+                This is used to specify how email is sent, or if it is sent at 
+                all.  There are several options included for different MTAs, 
+                along with two additional options that disable email sending.  
+                "Test" does not send mail, but instead saves it in 
+                <filename>data/mailer.testfile</filename> for later review.  
+                "None" disables email sending entirely.
+              </para>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              mailfrom
+            </term>
+            <listitem>
+              <para>
+                This is the email address that will appear in the "From" field
+                of all emails sent by this Bugzilla installation. Some email
+                servers require mail to be from a valid email address, therefore
+                it is recommended to choose a valid email address here.
+              </para>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              sendmailnow
+            </term>
+            <listitem>
+              <para>
+                When Bugzilla is using Sendmail older than 8.12, turning this option
+                off will improve performance by not waiting for Sendmail to actually
+                send mail.  If Sendmail 8.12 or later is being used, there is 
+                nothing to gain by turning this off.  If another MTA is being used, 
+                such as Postfix, then this option *must* be turned on (even if you 
+                are using the fake sendmail executable that Postfix provides).
+              </para>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              whinedays
+            </term>
+            <listitem>
+              <para>
+                Set this to the number of days you want to let bugs go
+                in the NEW or REOPENED state before notifying people they have
+                untouched new bugs. If you do not plan to use this feature, simply 
+                do not set up the whining cron job described in the installation
+                instructions, or set this value to "0" (never whine).
+              </para>
+            </listitem>
+          </varlistentry>
+
+          <varlistentry>
+            <term>
+              globalwatcher
+            </term>
+            <listitem>
+              <para>
+                This allows you to define specific users who will
+                receive notification each time a new bug in entered, or when
+                an existing bug changes, according to the normal groupset
+                permissions. It may be useful for sending notifications to a
+                mailing-list, for instance.
+              </para>
+            </listitem>
+          </varlistentry>
+
+        </variablelist>
+
+        </section>
+
+        <section id="param-patchviewer">
+          <title>Patch Viewer</title>
           <para>
-            Set this to the number of days you want to let bugs go
-            in the NEW or REOPENED state before notifying people they have
-            untouched new bugs. If you do not plan to use this feature, simply 
-            do not set up the whining cron job described in the installation
-            instructions, or set this value to "0" (never whine).
+            This page contains configuration parameters for the CVS server, 
+            Bonsai server and LXR server that Bugzilla will use to enable the
+            features of the Patch Viewer. Bonsai is a tool that enables queries 
+            to a CVS tree. LXR is a tool that can cross reference and index source
+            code.
           </para>
-        </listitem>
-      </varlistentry>
+        </section>
 
-      <varlistentry>
-        <term>
-          commenton*
-        </term>
-        <listitem>
+        <section id="param-querydefaults">
+          <title>Query Defaults</title>
           <para>
-            All these fields allow you to dictate what changes can pass
-            without comment, and which must have a comment from the
-            person who changed them.  Often, administrators will allow
-            users to add themselves to the CC list, accept bugs, or
-            change the Status Whiteboard without adding a comment as to
-            their reasons for the change, yet require that most other
-            changes come with an explanation.
+            This page controls the default behavior of Bugzilla in regards to 
+            several aspects of querying bugs. Options include what the default
+            query options are, what the "My Bugs" page returns, whether users
+            can freely add bugs to the quip list, and how many duplicate bugs are 
+            needed to add a bug to the "most frequently reported" list.
           </para>
+        </section>
 
+        <section id="param-shadowdatabase">
+          <title>Shadow Database</title>
+          <para>
+            This page controls whether a shadow database is used, and all the
+            parameters associated with the shadow database. Bugzilla
+            uses the MyISAM table type in MySQL, which supports
+            only table-level write locking. With MyISAM, any time someone is making a change to 
+            a bug, the entire table is locked until the write operation is complete.
+            Locking for write also blocks reads until the write is complete.
+          </para> 
           <para>
-            Set the "commenton" options according to your site policy. It
-            is a wise idea to require comments when users resolve, reassign, or
-            reopen bugs at the very least. 
+            The <quote>shadowdb</quote> parameter was designed to get around
+            this limitation. While only a single user is allowed to write to
+            a table at a time, reads can continue unimpeded on a read-only
+            shadow copy of the database.
           </para>
-
           <note>
             <para>
-              It is generally far better to require a developer comment
-              when resolving bugs than not. Few things are more annoying to bug
-              database users than having a developer mark a bug "fixed" without
-              any comment as to what the fix was (or even that it was truly
-              fixed!)
+              The shadow database is not automatically updated. Replication must
+              be set up to keep the shadow database in sync with the main database.
             </para>
           </note>
-        </listitem>
-      </varlistentry>
 
-      <varlistentry>
-        <term>
-          supportwatchers
-        </term>
-        <listitem>
-          <para>
-            Turning on this option allows users to ask to receive copies 
-            of bug mail sent to another user.  Watching a user with
-            different group permissions is not a way to 'get around' the
-            system; copied emails are still subject to the normal groupset
-            permissions of a bug, and <quote>watchers</quote> will only be 
-            copied on emails from bugs they would normally be allowed to view. 
-          </para> 
-        </listitem>
-      </varlistentry>
-
-
-      <varlistentry>
-        <term>
-          noresolveonopenblockers
-        </term>
-        <listitem>
-          <para>
-            This option will prevent users from resolving bugs as FIXED if
-            they have unresolved dependencies. Only the FIXED resolution
-            is affected. Users will be still able to resolve bugs to
-            resolutions other than FIXED if they have unresolved dependent
-            bugs.
-          </para>
-        </listitem>
-      </varlistentry>
-
-      <varlistentry>
-        <term>
-          sendmailnow
-        </term>
-        <listitem>
+        </section>
+
+        <section id="admin-usermatching">
+          <title>User Matching</title>
           <para>
-            When Bugzilla is using Sendmail older than 8.12, turning this option
-            off will improve performance by not waiting for Sendmail to actually
-            send mail.  If Sendmail 8.12 or later is being used, there is 
-            nothing to gain by turning this off.  If another MTA is being used, 
-            such as Postfix, then this option *must* be turned on (even if you 
-            are using the fake sendmail executable that Postfix provides).
+            The settings on this page control how users are selected and queried
+            when adding a user to a bug. For example, users need to be selected
+            when choosing who the bug is assigned to, adding to the CC list or 
+            selecting a QA contact. With the "usemenuforusers" parameter, it is 
+            possible to configure Bugzilla to 
+            display a list of users in the fields instead of an empty text field.
+            This should only be used in Bugzilla installations with a small number
+            of users. If users are selected via a text box, this page also
+            contains parameters for how user names can be queried and matched
+            when entered.
           </para>
-        </listitem>
-      </varlistentry>
 
-    </variablelist>
+        </section>
+
   </section>
 
   <section id="useradmin">
@@ -355,25 +895,33 @@
         <para>
           If you have <quote>editusers</quote> privileges or if you are allowed
           to grant privileges for some groups, the <quote>Users</quote> link
-          appears in the footer.
+          will appear in the Administration page.
         </para>
 
         <para>
-          The first screen you get is a search form to search for existing user
-          accounts. You can run searches based either on the ID, real name or
-          login name (i.e. the email address in most cases) of users. You can
-          search in different ways the listbox to the right of the text entry
+          The first screen is a search form to search for existing user
+          accounts. You can run searches based either on the user ID, real
+          name or login name (i.e. the email address, or just the first part
+          of the email address if the "emailsuffix" parameter is set).
+          The search can be conducted
+          in different ways using the listbox to the right of the text entry
           box. You can match by case-insensitive substring (the default),
           regular expression, a <emphasis>reverse</emphasis> regular expression
-          match, which finds every user name which does NOT match the regular
-          expression, or the exact string if you know exactly who you are looking for.
+          match (which finds every user name which does NOT match the regular
+          expression), or the exact string if you know exactly who you are
+          looking for. The search can be restricted to users who are in a
+          specific group. By default, the restriction is turned off.
         </para>
 
         <para>
-          You can also restrict your search to users being in some specific group.
-          By default, the restriction is turned off. Then you get a list of
-          users matching your criteria, and clicking their login name lets you
-          edit their properties.
+          The search returns a list of
+          users matching your criteria. User properties can be edited by clicking
+          the login name. The Account History of a user can be viewed by clicking
+          the "View" link in the Account History column. The Account History
+          displays changes that have been made to the user account, the time of
+          the change and the user who made the change. For example, the Account
+          History page will display details of when a user was added or removed
+          from a group.
         </para>
       </section>
 
@@ -648,192 +1196,534 @@
     </section>
   </section>
 
-  <section id="classifications">
+  <section id="classifications" xreflabel="Classifications">
     <title>Classifications</title>
 
     <para>Classifications tend to be used in order to group several related
     products into one distinct entity.</para>
 
-    <para>The classifications layer is disabled by default; it can be turned
-    on or off using the useclassification parameter,
-    in the <emphasis>Bug Fields</emphasis> section of the edit parameters screen.</para>
+    <para>The classifications layer is disabled by default; it can be turned
+    on or off using the useclassification parameter,
+    in the <emphasis>Bug Fields</emphasis> section of the edit parameters screen.</para>
+
+    <para>Access to the administration of classifications is controlled using
+    the <emphasis>editclassifications</emphasis> system group, which defines
+    a privilege for creating, destroying, and editing classifications.</para>
+
+    <para>When activated, classifications will introduce an additional
+    step when filling bugs (dedicated to classification selection), and they
+    will also appear in the advanced search form.</para>
+  </section>
+
+  <section id="products" xreflabel="Products">
+    <title>Products</title>
+
+    <para>
+    <glossterm linkend="gloss-product" baseform="product">
+    Products</glossterm> typically represent real-world
+    shipping products. Products can be given 
+    <xref linkend="classifications"/>. 
+    For example, if a company makes computer games, 
+    they could have a classification of "Games", and a separate
+    product for each game. This company might also have a 
+    <quote>Common</quote> product for units of technology used 
+    in multiple games, and perhaps a few special products that
+    represent items that are not actually shipping products 
+    (for example, "Website", or "Administration").
+    </para>
+
+    <para>
+    Many of Bugzilla's settings are configurable on a per-product
+    basis. The number of <quote>votes</quote> available to 
+    users is set per-product, as is the number of votes
+    required to move a bug automatically from the UNCONFIRMED 
+    status to the NEW status.
+    </para>
+
+    <para>
+    When creating or editing products the following options are
+    available: 
+    </para> 
+
+    <variablelist>
+
+      <varlistentry>
+        <term>
+          Product
+        </term>
+        <listitem>
+          <para> 
+            The name of the product
+          </para>
+        </listitem>
+      </varlistentry>
+
+      <varlistentry>
+        <term>
+          Description
+        </term>
+        <listitem>
+          <para> 
+            A brief description of the product
+          </para>
+        </listitem>
+      </varlistentry>
+
+      <varlistentry>
+        <term>
+          URL describing milestones for this product
+        </term>
+        <listitem>
+          <para> 
+            If there is reference URL, provide it here
+          </para>
+        </listitem>
+      </varlistentry>
+
+      <varlistentry>
+        <term>
+          Default milestone
+        </term>
+        <listitem>
+          <para> 
+            Select the default milestone for this product.
+          </para>
+        </listitem>
+      </varlistentry>
+
+      <varlistentry>
+        <term>
+          Closed for bug entry
+        </term>
+        <listitem>
+          <para> 
+            Select this box to prevent new bugs from being
+            entered against this product.
+          </para>
+        </listitem>
+      </varlistentry>
+
+      <varlistentry>
+        <term>
+          Maximum votes per person
+        </term>
+        <listitem>
+          <para> 
+            Maximum votes a user is allowed to give for this 
+            product
+          </para>
+        </listitem>
+      </varlistentry>
+
+      <varlistentry>
+        <term>
+          Maximum votes a person can put on a single bug
+        </term>
+        <listitem>
+          <para> 
+            Maximum votes a user is allowed to give for this 
+            product in a single bug
+          </para>
+        </listitem>
+      </varlistentry>
+
+      <varlistentry>
+        <term>
+          Confirmation threshold
+        </term>
+        <listitem>
+          <para> 
+            Number of votes needed to automatically remove any
+            bug against this product from the UNCONFIRMED state
+          </para>
+        </listitem>
+      </varlistentry>
+
+      <varlistentry>
+        <term>
+          Version
+        </term>
+        <listitem>
+          <para> 
+            Specify which version of the product bugs will be
+            entered against.
+          </para>
+        </listitem>
+      </varlistentry>
+
+      <varlistentry>
+        <term>
+          Create chart datasets for this product
+        </term>
+        <listitem>
+          <para> 
+            Select to make chart datasets available for this product.
+          </para>
+        </listitem>
+      </varlistentry>
+
+    </variablelist>
+
+    <para>
+    When editing a product there is also a link to edit Group Access Controls,
+    see <xref linkend="product-group-controls"/>.
+    </para>
+
+    <section id="create-product">
+      <title>Creating New Products</title>
+
+    <para>
+    To create a new product:
+    </para>
+
+    <orderedlist>
+      <listitem>
+        <para> 
+        Select <quote>Products</quote> from the page footer.
+        </para>
+      </listitem>
+
+      <listitem>
+        <para>
+        Select the <quote>Add</quote> link in the bottom right.
+        </para>
+      </listitem>
+
+      <listitem>
+        <para>
+        Enter the name of the product and a description. The
+        Description field may contain HTML.
+        </para>
+      </listitem>
+
+      <listitem>
+        <para>
+        When the product is created, Bugzilla will give a message
+        stating that a component must be created before any bugs can
+        be entered against the new product. Follow the link to create
+        a new component. See <xref linkend="components"/> for more
+        information.
+        </para>
+      </listitem>
+    </orderedlist>
+
+    </section>
+
+    <section id="edit-products">
+      <title>Editing Products</title>
+
+      <para>
+      To edit an existing product, click the "Products" link from the 
+      page footer. If the 'useclassification' parameter is
+      turned on, a table of existing classifications is displayed,
+      including an "Unclassified" category. The table indicates how many products
+      are in each classification. Click on the classification name to see its
+      products. If the 'useclassification' parameter is not in use, the table 
+      lists all products directly. The product table summarizes the information 
+      about the product defined
+      when the product was created. Click on the product name to edit these
+      properties, and to access links to other product attributes such as the
+      product's components, versions, milestones, and group access controls.
+      </para>
+
+      </section>
+
+      <section id="comps-vers-miles-products">
+        <title>Adding or Editing Components, Versions and Target Milestones</title>
+        <para>
+          To edit existing, or add new, Components, Versions or Target Milestones 
+          to a Product, select the "Edit Components", "Edit Versions" or "Edit
+          Milestones" links from the "Edit Product" page. A table of existing 
+          Components, Versions or Milestones is displayed. Click on a item name 
+          to edit the properties of that item. Below the table is a link to add 
+          a new Component, Version or Milestone. 
+        </para>
+        <para>
+          For more information on components, see <xref linkend="components"/>.
+        </para>
+        <para>
+          For more information on versions, see <xref linkend="versions"/>.
+        </para>
+        <para>
+          For more information on milestones, see <xref linkend="milestones"/>.
+        </para>
+      </section>
+
+      <section id="product-group-controls">
+        <title>Assigning Group Controls to Products</title>
+
+        <para> 
+        On the <quote>Edit Product</quote> page, there is a link called 
+        <quote>Edit Group Access Controls</quote>. The settings on this page 
+        control the relationship of the groups to the product being edited.
+        </para> 
+
+        <para>
+        Group Access Controls are an important aspect of using groups for 
+        isolating products and restricting access to bugs filed against those
+        products. For more information on groups, including how to create, edit
+        add users to, and alter permission of, see <xref linkend="groups"/>.
+        </para>
+
+        <para>
+        After selecting the "Edit Group Access Controls" link from the "Edit
+        Product" page, a table containing all user-defined groups for this 
+        Bugzilla installation is displayed. The system groups that are created
+        when Bugzilla is installed are not applicable to Group Access Controls.
+        Below is description of what each of these fields means.
+        </para>
+
+        <para>
+        Groups may be applicable (e.g bugs in this product can be associated
+        with this group) , default (e.g. bugs in this product are in this group
+        by default), and mandatory (e.g. bugs in this product must be associated
+        with this group) for each product. Groups can also control access 
+        to bugs for a given product, or be used to make bugs for a product 
+        totally read-only unless the group restrictions are met. The best way to
+        understand these relationships is by example. See 
+        <xref linkend="group-control-examples"/> for examples of 
+        product and group relationships.
+        </para>
+  
+        <note>
+          <para>
+            Products and Groups are not limited to a one-to-one relationship. 
+            Multiple groups can be associated with the same product, and groups
+            can be associated with more than one product. 
+          </para>
+        </note> 
+
+        <para>
+        If any group has <emphasis>Entry</emphasis> selected, then the 
+        product will restrict bug entry to only those users 
+        who are members of <emphasis>all</emphasis> the groups with 
+        <emphasis>Entry</emphasis> selected.
+        </para>
+
+        <para>
+        If any group has <emphasis>Canedit</emphasis> selected, 
+        then the product will be read-only for any users 
+        who are not members of <emphasis>all</emphasis> of the groups with
+        <emphasis>Canedit</emphasis> selected. <emphasis>Only</emphasis> users who 
+        are members of all the <emphasis>Canedit</emphasis> groups 
+        will be able to edit bugs for this product. This is an additional 
+        restriction that enables finer-grained control over products rather 
+        than just all-or-nothing access levels.
+        </para>
+
+        <para>
+        The following settings let you 
+        choose privileges on a <emphasis>per-product basis</emphasis>.
+        This is a convenient way to give privileges to 
+        some users for some products only, without having 
+        to give them global privileges which would affect 
+        all products.
+        </para>
+
+        <para>
+        Any group having <emphasis>editcomponents</emphasis> 
+        selected  allows users who are in this group to edit all 
+        aspects of this product, including components, milestones 
+        and versions.
+        </para>
+
+        <para>
+        Any group having <emphasis>canconfirm</emphasis> selected 
+        allows users who are in this group to confirm bugs 
+        in this product.
+        </para>
+
+        <para>
+        Any group having <emphasis>editbugs</emphasis> selected allows 
+        users who are in this group to edit all fields of 
+        bugs in this product.
+        </para>
+
+        <para>
+        The <emphasis>MemberControl</emphasis> and 
+        <emphasis>OtherControl</emphasis> are used in tandem to determine which 
+        bugs will be placed in this group. The only allowable combinations of
+        these two parameters are listed in a table on the "Edit Group Access Controls"
+        page. Consult this table for details on how these fields can be used.
+        Examples of different uses are described below.
+        </para>
+
+      <section id="group-control-examples">
+      <title>Common Applications of Group Controls</title>
+
+      <para>
+        The use of groups is best explained by providing examples that illustrate
+        configurations for common use cases. The examples follow a common syntax:
+        <emphasis>Group: Entry, MemberControl, OtherControl, CanEdit,
+        EditComponents, CanConfirm, EditBugs</emphasis>. Where "Group" is the name
+        of the group being edited for this product. The other fields all
+        correspond to the table on the "Edit Group Access Controls" page. If any
+        of these options are not listed, it means they are not checked.      
+      </para>
+      
+          <para>
+            Basic Product/Group Restriction
+          </para>
+
+        <para>
+          Suppose there is a product called "Bar". The 
+          "Bar" product can only have bugs entered against it by users in the
+          group "Foo". Additionally, bugs filed against product "Bar" must stay
+          restricted to users to "Foo" at all times. Furthermore, only members
+          of group "Foo" can edit bugs filed against product "Bar", even if other
+          users could see the bug. This arrangement would achieved by the
+          following:
+        </para>
+
+        <programlisting>
+Product Bar: 
+foo: ENTRY, MANDATORY/MANDATORY, CANEDIT
+        </programlisting>
+
+        <para>
+          Perhaps such strict restrictions are not needed for product "Bar". A 
+          more lenient way to configure product "Bar" and group "Foo" would be:
+        </para>
+
+        <programlisting>
+Product Bar: 
+foo: ENTRY, SHOWN/SHOWN, EDITCOMPONENTS, CANCONFIRM, EDITBUGS
+        </programlisting>
+
+        <para>
+          The above indicates that for product "Bar", members of group "Foo" can
+          enter bugs. Any one with permission to edit a bug against product "Bar"
+          can put the bug
+          in group "Foo", even if they themselves are not in "Foo". Anyone in group
+          "Foo" can edit all aspects of the components of product "Bar", can confirm
+          bugs against product "Bar", and can edit all fields of any bug against
+          product "Bar".
+        </para>
+ 
+          <para>
+            General User Access With Security Group
+          </para>
+
+             <para>
+               To permit any user to file bugs against "Product A",
+               and to permit any user to submit those bugs into a
+               group called "Security":  
+            </para>
+
+      <programlisting> 
+Product A:
+security: SHOWN/SHOWN
+      </programlisting>
+
+          <para>
+            General User Access With A Security Product
+          </para>
+
+          <para>
+            To permit any user to file bugs against product called "Security"
+            while keeping those bugs from becoming visible to anyone
+            outside the group "SecurityWorkers" (unless a member of the
+            "SecurityWorkers" group removes that restriction):
+          </para>
+
+          <programlisting> 
+Product Security:
+securityworkers: DEFAULT/MANDATORY
+          </programlisting>
 
-    <para>Access to the administration of classifications is controlled using
-    the <emphasis>editclassifications</emphasis> system group, which defines
-    a privilege for creating, destroying, and editing classifications.</para>
+          <para>
+            Product Isolation With a Common Group
+          </para>
 
-    <para>When activated, classifications will introduce an additional
-    step when filling bugs (dedicated to classification selection), and they
-    will also appear in the advanced search form.</para>
-  </section>
+          <para>
+            To permit users of "Product A" to access the bugs for
+            "Product A", users of "Product B" to access the bugs for 
+            "Product B", and support staff, who are members of the "Support 
+            Group" to access both, three groups are needed:
+          </para>
 
-  <section id="products">
-    <title>Products</title>
+          <orderedlist>
 
-    <para>
-    <glossterm linkend="gloss-product" baseform="product">
-    Products</glossterm>
-    tend to represent real-world
-    shipping products. E.g. if your company makes computer games, 
-    you should have one product per game, perhaps a 
-    <quote>Common</quote> product for units of technology used 
-    in multiple games, and maybe a few special products 
-    (Website, Administration...)
-    </para>
+          <listitem>
+            <para>Support Group: Contains members of the support staff.</para>
+          </listitem>
 
-    <para>
-    Many of Bugzilla's settings are configurable on a per-product
-    basis. The number of <quote>votes</quote> available to 
-    users is set per-product, as is the number of votes
-    required to move a bug automatically from the UNCONFIRMED 
-    status to the NEW status.
-    </para>
+          <listitem>
+            <para>AccessA Group: Contains users of product A and the Support group.</para>
+          </listitem>
 
-    <para>
-    To create a new product:
-    </para>
+          <listitem>
+            <para>AccessB Group: Contains users of product B and the Support group.</para>
+          </listitem>
 
-    <orderedlist>
-      <listitem>
-        <para> 
-        Select <quote>products</quote> from the footer.
-        </para>
+          </orderedlist>
 
-      </listitem>
+          <para>
+            Once these three groups are defined, the product group controls
+            can be set to:
+          </para>
 
-      <listitem>
-        <para>
-        Select the <quote>Add</quote> link in the bottom right.
-        </para>
-      </listitem>
+          <programlisting>
+Product A:
+AccessA: ENTRY, MANDATORY/MANDATORY
+Product B:
+AccessB: ENTRY, MANDATORY/MANDATORY
+        </programlisting>
 
-      <listitem>
         <para>
-        Enter the name of the product and a description. The
-        Description field may contain HTML.
+         Perhaps the "Support Group" wants more control. For example, 
+         the "Support Group"  could be permitted to make bugs inaccessible to 
+         users of both groups "AccessA" and "AccessB". 
+         Then, the "Support Group" could be permitted to publish
+         bugs relevant to all users in a third product (let's call it 
+         "Product Common") that is read-only
+         to anyone outside the "Support Group". In this way the "Support Group" 
+         could control bugs that should be seen by both groups. 
+         That configuration would be:
         </para>
-      </listitem>
-    </orderedlist>
 
+      <programlisting>
+Product A:
+AccessA: ENTRY, MANDATORY/MANDATORY
+Support: SHOWN/NA
+Product B:
+AccessB: ENTRY, MANDATORY/MANDATORY
+Support: SHOWN/NA
+Product Common:
+Support: ENTRY, DEFAULT/MANDATORY, CANEDIT
+      </programlisting>
 
-<section>
-      <title>Assigning Group Controls to Products</title>
-      <para> 
-      On the <quote>Product Edit</quote> page, 
-      there is a link called 
-      <quote>Edit Group Access Controls</quote>. 
-      The settings on this page control the relationship 
-      of the groups to the product being edited.
-      </para> 
-      <para>
-      Groups may be applicable, default, and 
-      mandatory for each product. Groups can also control access 
-      to bugs for a given product, or be used to make bugs 
-      for a product totally read-only unless the group 
-      restrictions are met.
-      </para>
-      <para>
-      If any group has <emphasis>Entry</emphasis> selected, then the 
-      product will restrict bug entry to only those users 
-      who are members of all the groups with 
-      <emphasis>Entry</emphasis> selected.
-      </para>
-      <para>
-      If any group has <emphasis>Canedit</emphasis> selected, 
-      then the product will be read-only for any users 
-      who are not members of all of the groups with
-      <emphasis>Canedit</emphasis> selected. ONLY users who 
-      are members of all the <emphasis>Canedit</emphasis> groups 
-      will be able to edit. This is an 
-      additional restriction that further limits 
-      what can be edited by a user.
-      </para>
-      <para>
-      The following settings let you 
-      choose privileges on a <emphasis>per-product basis</emphasis>.
-      This is a convenient way to give privileges to 
-      some users for some products only, without having 
-      to give them global privileges which would affect 
-      all products.
-      </para>
-      <para>
-      Any group having <emphasis>editcomponents</emphasis> 
-      selected  allows users who are in this group to edit all 
-      aspects of this product, including components, milestones 
-      and versions.
-      </para>
-      <para>
-      Any group having <emphasis>canconfirm</emphasis> selected 
-      allows users who are in this group to confirm bugs 
-      in this product.
-      </para>
-      <para>
-      Any group having <emphasis>editbugs</emphasis> selected allows 
-      users who are in this group to edit all fields of 
-      bugs in this product.
-      </para>
-      <para>
-      The <emphasis>MemberControl</emphasis> and 
-      <emphasis>OtherControl</emphasis> fields indicate which 
-      bugs will be placed in this group according 
-      to the following definitions.
-      </para>
-      <para>
-      For each group, it is possible to specify if 
-      membership in that group is:
-      </para>
-      <orderedlist>
-        <listitem>
-          <para>
-          Required for bug entry. 
-          </para>
-        </listitem>
-        <listitem>
           <para>
-          Not applicable to this product(NA),
-          a possible restriction for a member of the 
-          group to place on a bug in this product(Shown),
-          a default restriction for a member of the 
-          group to place on a bug in this product(Default),
-          or a mandatory restriction to be placed on bugs 
-          in this product(Mandatory).
+            Make a Product Read Only
           </para>
-        </listitem>
-        <listitem>
+
           <para>
-          Not applicable by non-members to this product(NA),
-          a possible restriction for a non-member of the 
-          group to place on a bug in this product(Shown),
-          a default restriction for a non-member of the 
-          group to place on a bug in this product(Default),
-          or a mandatory restriction to be placed on bugs 
-          in this product when entered by a non-member(Mandatory).
+            Sometimes a product is retired and should no longer have
+            new bugs filed against it (for example, an older version of a software
+            product that is no longer supported). A product can be made read-only
+            by creating a group called "readonly" and adding products to the
+            group as needed:
           </para>
-        </listitem>
-        <listitem>
+
+         <programlisting>
+Product A:
+ReadOnly: ENTRY, NA/NA, CANEDIT
+         </programlisting>
+
+        <note>
           <para>
-          Required in order to make <emphasis>any</emphasis> change
-          to bugs in this product <emphasis>including comments.</emphasis>
+            For more information on Groups outside of how they relate to products
+            see <xref linkend="groups"/>.
           </para>
-        </listitem>
-      </orderedlist>
-      <para>These controls are often described in this order, so a 
-      product that requires a user to be a member of group "foo" 
-      to enter a bug and then requires that the bug stay restricted
-      to group "foo" at all times and that only members of group "foo"
-      can edit the bug even if they otherwise could see the bug would 
-      have its controls summarized by...</para>
-      <programlisting> 
-foo: ENTRY, MANDATORY/MANDATORY, CANEDIT
-      </programlisting>
-      
-    </section>
+        </note>
 
+       </section>
 
+    </section>
 
   </section>
 
-  <section id="components">
+  <section id="components" xreflabel="Components">
     <title>Components</title>
 
     <para>Components are subsections of a Product. E.g. the computer game 
@@ -1395,6 +2285,30 @@
 
   </section> <!-- flags -->
 
+  <section id="keywords">
+    <title>Keywords</title>
+
+    <para>
+    The administrator can define keywords which can be used to tag and
+    categorise bugs. For example, the keyword "regression" is commonly used.
+    A company might have a policy stating all regressions
+    must be fixed by the next release - this keyword can make tracking those
+    bugs much easier.
+    </para>
+    <para>
+    Keywords are global, rather than per-product. If the administrator changes
+    a keyword currently applied to any bugs, the keyword cache must be rebuilt
+    using the <xref linkend="sanitycheck"/> script. Currently keywords can not
+    be marked obsolete to prevent future usage.
+    </para>
+    <para>
+    Keywords can be created, edited or deleted by clicking the "Keywords"
+    link in the footer. There are two fields for each keyword - the keyword
+    itself and a brief description. Once created, keywords can be selected
+    and applied to individual bugs in that bug's "Details" section.
+    </para>
+  </section>
+
   <section id="custom-fields">
     <title>Custom Fields</title>
 
@@ -1660,28 +2574,70 @@
   <section id="groups">
     <title>Groups and Group Security</title>
 
-    <para>Groups allow the administrator
-    to isolate bugs or products that should only be seen by certain people.
-    The association between products and groups is controlled from
-    the product edit page under <quote>Edit Group Controls.</quote>
+    <para>
+    Groups allow for separating bugs into logical divisions.
+    Groups are typically used to
+    to isolate bugs that should only be seen by certain people. For
+    example, a company might create a different group for each one of its customers
+    or partners. Group permissions could be set so that each partner or customer would
+    only have access to their own bugs. Or, groups might be used to create
+    variable access controls for different departments within an organization.
+    Another common use of groups is to associate groups with products,
+    creating isolation and access control on a per-product basis.
     </para>
 
     <para>
-    If the makeproductgroups param is on, a new group will be automatically
-    created for every new product. It is primarily available for backward
-    compatibility with older sites. 
-    </para>
-    <para>
-      Note that group permissions are such that you need to be a member
-      of <emphasis>all</emphasis> the groups a bug is in, for whatever
-      reason, to see that bug. Similarly, you must be a member 
-      of <emphasis>all</emphasis> of the entry groups for a product 
-      to add bugs to a product and you must be a member 
-      of <emphasis>all</emphasis> of the canedit groups for a product
-      in order to make <emphasis>any</emphasis> change to bugs in that
-      product.
-    </para>    
-    <note>
+    Groups and group behaviors are controlled in several places:
+    </para>
+
+      <orderedlist>
+
+         <listitem>
+           <para>
+             The group configuration page. To view or edit existing groups, or to
+             create new groups, access the "Groups" link from the page footer.
+             This section of the manual deals primarily with the aspect of
+             group controls accessed on this page.  
+           </para>
+         </listitem> 
+
+        <listitem>
+          <para>
+            Global configuration parameters. Bugzilla has several parameters 
+            that control the overall default group behavior and restriction
+            levels. For more information on the parameters that control 
+            group behavior globally, see <xref linkend="param-group-security"/>.
+          </para>
+
+         </listitem>
+
+         <listitem>
+          <para>
+            Product association with groups. Most of the functionality of groups
+            and group security is controlled at the product level. Some aspects
+            of group access controls for products are discussed in this section,
+            but for more detail see <xref linkend="product-group-controls"/>.
+          </para>
+         </listitem>
+
+         <listitem>
+          <para>
+            Group access for users. See <xref linkend="users-and-groups"/> for
+            details on how users are assigned group access.
+          </para>
+         </listitem>
+
+      </orderedlist>
+
+    <para>
+      Group permissions are such that if a bug belongs to a group, only members
+      of that group can see the bug. If a bug is in more than one group, only
+      members of <emphasis>all</emphasis> the groups that the bug is in can see
+      the bug. For information on granting read-only access to certain people and
+      full edit access to others, see <xref linkend="product-group-controls"/>.
+     </para> 
+
+     <note>
       <para>
         By default, bugs can also be seen by the Assignee, the Reporter, and 
         by everyone on the CC List, regardless of whether or not the bug would 
@@ -1690,158 +2646,222 @@
         section that starts with <quote>Users in the roles selected below...</quote>
         and un-checking the box next to either 'Reporter' or 'CC List' (or both).
       </para>
-    </note>
-    <section>
+    </note> 
+
+    <section id="create-groups">
       <title>Creating Groups</title>
-      <para>To create Groups:</para>
+
+      <para>
+        To create a new group, follow the steps below:
+      </para>
   
       <orderedlist>
+
         <listitem>
-          <para>Select the <quote>groups</quote>
-          link in the footer.</para>
+          <para>
+            Select the <quote>Groups</quote> link in the page footer.
+          </para>
         </listitem>
   
         <listitem>
-          <para>Take a moment to understand the instructions on the <quote>Edit
-          Groups</quote> screen, then select the <quote>Add Group</quote> link.</para>
+          <para>
+            A table of all the existing groups is displayed. Below the table is a
+            description of all the fields. To create a new group, select the 
+            <quote>Add Group</quote> link under the table of existing groups.
+          </para>
         </listitem>
   
         <listitem>
-          <para>Fill out the <quote>Group</quote>, <quote>Description</quote>, 
-           and <quote>User RegExp</quote> fields. 
-           <quote>User RegExp</quote> allows you to automatically
-           place all users who fulfill the Regular Expression into the new group. 
-           When you have finished, click <quote>Add</quote>.</para>
-           <para>Users whose email addresses match the regular expression
-           will automatically be members of the group as long as their 
-           email addresses continue to match the regular expression.</para>
-           <note>
-             <para>This is a change from 2.16 where the regular expression
-             resulted in a user acquiring permanent membership in a group.
-             To remove a user from a group the user was in due to a regular
-             expression in version 2.16 or earlier, the user must be explicitly
-             removed from the group. This can easily be done by pressing
-             buttons named 'Remove Memberships' or 'Remove Memberships
-             included in regular expression' under the table.</para>
-           </note>
-           <warning>
-             <para>If specifying a domain in the regexp, make sure you end
-             the regexp with a $. Otherwise, when granting access to 
-             "@mycompany\.com", you will allow access to 
-             'badperson mycompany com cracker net'. You need to use 
-             '@mycompany\.com$' as the regexp.</para>
-           </warning>
-        </listitem>
-        <listitem>
-          <para>If you plan to use this group to directly control
-          access to bugs, check the "use for bugs" box. Groups
-          not used for bugs are still useful because other groups
-          can include the group as a whole.</para>
+          <para>
+            There are four fields to fill out. These fields are documented below
+            the form. Choose a name and description for the group. Decide whether
+            this group should be used for bugs (in all likelihood this should be
+            selected). Optionally, choose a regular expression that will
+            automatically add any matching users to the group. The regular
+            expression can be useful, for example, to automatically put all users
+            from the same company into one group (if the group is for a specific
+            customer or partner). 
+          </para>
+            <note>
+             <para>
+               If <quote>User RegExp</quote> is filled out, users whose email 
+               addresses match the regular expression will automatically be 
+               members of the group as long as their email addresses continue 
+               to match the regular expression. If their email address changes
+               and no longer matches the regular expression, they will be removed
+               from the group. Versions 2.16 and older of Bugzilla did not automatically
+               remove users who's email addresses no longer matched the RegExp.
+             </para>
+            </note>
+            <warning>
+             <para>
+               If specifying a domain in the regular expression, end
+               the regexp with a "$". Otherwise, when granting access to 
+               "@mycompany\.com", access will also be granted to 
+               'badperson mycompany com cracker net'. Use the syntax,
+               '@mycompany\.com$' for the regular expression.
+             </para>
+            </warning>
         </listitem>
+
         <listitem>
-          <para>After you add your new group, edit the new group.  On the
-          edit page, you can specify other groups that should be included
+          <para>
+          After the new group is created, it can be edited for additional options. 
+          The "Edit Group" page allows for specifying other groups that should be included
           in this group and which groups should be permitted to add and delete
-          users from this group.</para>
+          users from this group. For more details, see <xref linkend="edit-groups"/>.
+          </para>
         </listitem>
       </orderedlist>
   
     </section>
-    <section>
+ 
+    <section id="edit-groups">
+      <title>Editing Groups and Assigning Group Permissions</title>
+
+      <para>
+        To access the "Edit Groups" page, select the 
+        <quote>Groups</quote> link in the page footer. 
+        A table of all the existing groups is displayed. Click on a group name
+        you wish to edit or control permissions for.
+      </para>
+
+      <para>
+       The "Edit Groups" page contains the same four fields present when
+       creating a new group. Below that are two additional sections, "Group
+       Permissions," and "Conversion of groups created with Bugzilla versions 
+       2.16 and prior". The "Conversion..." section compensates for the default
+       behavior of version 2.16 and prior by allowing for the mass removal of
+       members who were put in this group via the regular expression.  The
+       "Group Permissions" section requires further explanation.
+      </para>
+
+      <para>
+       The "Group Permissions" section on the "Edit Groups" page contains a table
+       listing each group next to two columns of check boxes. The first column is
+       marked "Grant" and the second is marked "Inherit". If the 
+       'usevisibilitygroups' parameter is in use (see
+       <xref linkend="parameters"/>) an additional column, "Visible", is displayed. 
+       The way these controls allow groups to relate
+       to one another is called <emphasis>inheritance</emphasis>. Use this table
+       to configure group permissions as follows (the discussion below assumes the
+       group being edited is called "Group1").
+      </para>
+   
+      <para>
+        For any group in the table, if "Visible" is checked (only applicable if
+        the 'usevisibilitygroups' parameter is in use), then all members of the
+        checked group will be able to see "Group1" and all of its members. Further,
+        <emphasis>only</emphasis> members of groups with "Visible" checked will
+        be aware of "Group1". 
+      </para>
+      <para>
+        For any group in the table, if "Grant" is checked then any members of
+        the checked groups will be able to grant (or revoke) membership in 
+        "Group1" to any other user - even if the users in the checked group 
+        are not administrators. In other words, the members of any checked 
+        group are like group administrators for "Group1".  
+      </para> 
+      <para>
+        For any group in the table, if "Inherit" is checked, then any members
+        of the checked group will also be members of "Group1". In other words,
+        members of any checked group will inherit membership in "Group1". 
+      </para>
+
+    </section>
+
+    <section id="users-and-groups">
       <title>Assigning Users to Groups</title>
-      <para>Users can become a member of a group in several ways.</para>
+
+      <para>
+        A User can become a member of a group in several ways:
+      </para>
+
       <orderedlist>
+
         <listitem>
-          <para>The user can be explicitly placed in the group by editing
-          the user's own profile</para>
+          <para>
+            The user can be explicitly placed in the group by editing
+            the user's profile. This can be done by accessing the "Users" link
+            from the page footer. Use the search form to find the user
+            you want to edit group membership for, and click on their email
+            address in the search results to edit their profile. The profile
+            page lists all the groups, and indicates if the user is a member of
+            the group either directly or indirectly. More information on indirect
+            group membership is below. For more details on User administration,
+            see <xref linkend="useradmin"/>.
+          </para>
         </listitem>
+
         <listitem>
-          <para>The group can include another group of which the user is
-          a member.</para>
+          <para>
+           The group can inherit members from other groups. This is indicated by 
+           square brackets around the check box  
+           next to the group name in the user's profile.
+           See <xref linkend="edit-groups"/> for details on group inheritance.
+          </para>
         </listitem>
+
         <listitem>
-          <para>The user's email address can match a regular expression
-          that the group specifies to automatically grant membership to
-          the group.</para>
+          <para>
+            The user's email address can match the regular expression
+            that has been specified to automatically grant membership to
+            the group. This is indicated by "*" around the check box by the
+            group name in the user's profile.
+            See <xref linkend="create-groups"/> for details on 
+            the regular expression option when creating groups.
+           </para>
         </listitem>
+
       </orderedlist>
+
     </section>
+
     <section>
      <title>Assigning Group Controls to Products</title>
+
      <para>
-     For information on assigning group controls to
-     products, see <xref linkend="products" />.
+     The primary functionality of groups is derived from the relationship of 
+     groups to products. The concepts around segregating access to bugs with
+     product group controls can be confusing. For details and examples on this
+     topic, see <xref linkend="product-group-controls" />.
      </para>
+
     </section>
-    
-    <section>
-    <title>Common Applications of Group Controls</title>
-      <section>
-      <title>General User Access With Security Group</title>
-      <para>To permit any user to file bugs in each product (A, B, C...) 
-      and to permit any user to submit those bugs into a security
-      group....</para>
-      <programlisting> 
-Product A...
-security: SHOWN/SHOWN
-Product B...
-security: SHOWN/SHOWN
-Product C...
-security: SHOWN/SHOWN
-      </programlisting>
-      </section>
-      <section>
-      <title>General User Access With A Security Product</title>
-      <para>To permit any user to file bugs in a Security product
-      while keeping those bugs from becoming visible to anyone
-      outside the securityworkers group unless a member of the
-      securityworkers group removes that restriction....</para>
-      <programlisting> 
-Product Security...
-securityworkers: DEFAULT/MANDATORY
-      </programlisting>
-      </section>
-      <section>
-      <title>Product Isolation With Common Group</title>
-      <para>To permit users of product A to access the bugs for
-      product A, users of product B to access product B, and support
-      staff to access both, 3 groups are needed</para>
-      <orderedlist>
-        <listitem>
-          <para>Support: Contains members of the support staff.</para>
-        </listitem>
-        <listitem>
-          <para>AccessA: Contains users of product A and the Support group.</para>
-        </listitem>
-        <listitem>
-          <para>AccessB: Contains users of product B and the Support group.</para>
-        </listitem>
-      </orderedlist>
-      <para>Once these 3 groups are defined, the products group controls
-      can be set to..</para>
-      <programlisting>
-Product A...
-AccessA: ENTRY, MANDATORY/MANDATORY
-Product B...
-AccessB: ENTRY, MANDATORY/MANDATORY
-      </programlisting>
-      <para>Optionally, the support group could be permitted to make
-      bugs inaccessible to the users and could be permitted to publish
-      bugs relevant to all users in a common product that is read-only
-      to anyone outside the support group. That configuration could
-      be...</para>
-      <programlisting>
-Product A...
-AccessA: ENTRY, MANDATORY/MANDATORY
-Support: SHOWN/NA
-Product B...
-AccessB: ENTRY, MANDATORY/MANDATORY
-Support: SHOWN/NA
-Product Common...
-Support: ENTRY, DEFAULT/MANDATORY, CANEDIT
-      </programlisting>
-      </section>
-    </section>
+
+  </section>
+
+  <section id="sanitycheck">
+    <title>Checking and Maintaining Database Integrity</title>
+
+    <para>
+    Over time it is possible for the Bugzilla database to become corrupt
+    or to have anomalies.
+    This could happen through normal usage of Bugzilla, manual database
+    administration outside of the Bugzilla user interface, or from some
+    other unexpected event. Bugzilla includes a "Sanity Check" script that
+    can perform several basic database checks, and repair certain problems or
+    inconsistencies. 
+    </para>
+    <para>
+    To run the "Sanity Check" script, log in as an Administrator and click the
+    "Sanity Check" link in the footer. Any problems that are found will be
+    displayed in red letters. If the script is capable of fixing a problem,
+    it will present a link to initiate the fix. If the script can not
+    fix the problem it will require manual database administration or recovery.
+    </para>
+    <para>
+    The "Sanity Check" script should be run on a regular basis as a matter of
+    best practice.
+    </para>
+    <warning>
+      <para>
+      The "Sanity Check" script is no substitute for a competent database
+      administrator. It is only designed to check and repair basic database
+      problems.
+      </para>
+    </warning>
+
   </section>
 
   <section id="upgrading">

Modified: trunk/docs/xml/conventions.xml
==============================================================================
--- trunk/docs/xml/conventions.xml	(original)
+++ trunk/docs/xml/conventions.xml	Fri Apr 11 17:31:30 2008
@@ -20,7 +20,7 @@
 
       <tbody>
         <row>
-          <entry>Warning</entry>
+          <entry>Caution</entry>
 
           <entry>
             <caution>
@@ -30,11 +30,11 @@
         </row>
 
         <row>
-          <entry>Hint</entry>
+          <entry>Hint or Tip</entry>
 
           <entry>
             <tip>
-              <para>Would you like a breath mint?</para>
+              <para>For best results... </para>
             </tip>
           </entry>
         </row>
@@ -50,7 +50,7 @@
         </row>
 
         <row>
-          <entry>Information requiring special attention</entry>
+          <entry>Warning</entry>
 
           <entry>
             <warning>

Modified: trunk/docs/xml/customization.xml
==============================================================================
--- trunk/docs/xml/customization.xml	(original)
+++ trunk/docs/xml/customization.xml	Fri Apr 11 17:31:30 2008
@@ -696,7 +696,7 @@
         versions, and you upgrade.
       </para>
     </warning>
-       
+      
     <para>
       Companies often have rules about which employees, or classes of employees,
       are allowed to change certain things in the bug system. For example, 
@@ -705,6 +705,16 @@
       designed to make it easy for you to write your own custom rules to define
       who is allowed to make what sorts of value transition.
     </para>
+
+    <para>
+     By default, assignees, QA owners and users
+     with <emphasis>editbugs</emphasis> privileges can edit all fields of bugs, 
+     except group restrictions (unless they are members of the groups they 
+     are trying to change). Bug reporters also have the ability to edit some 
+     fields, but in a more restrictive manner. Other users, without 
+     <emphasis>editbugs</emphasis> privileges, can not edit 
+     bugs, except to comment and add themselves to the CC list.
+    </para> 
     
     <para>
       For maximum flexibility, customizing this means editing Bugzilla's Perl 

Modified: trunk/docs/xml/faq.xml
==============================================================================
--- trunk/docs/xml/faq.xml	(original)
+++ trunk/docs/xml/faq.xml	Fri Apr 11 17:31:30 2008
@@ -316,6 +316,23 @@
       <title>Managerial Questions</title>
 
       <qandaentry>
+        <question id="faq-phb-deletebugs">
+          <para>
+            Is it possible to delete bug reports?
+          </para>
+        </question>
+        <answer>
+          <para>
+            Yes. You have to turn on the 'allowbugdeletion' parameter, which is
+            off by default. Note that you cannot delete bug reports one by one.
+            You have to move them in a product or component, e.g. named "Trash",
+            and then delete this product or component. The reason we make it
+            hard is that you generally don't want to do that. 
+          </para>
+        </answer>
+      </qandaentry>
+
+      <qandaentry>
         <question id="faq-phb-client">
           <para>
             Is Bugzilla web-based, or do you have to have specific software or

Modified: trunk/docs/xml/installation.xml
==============================================================================
--- trunk/docs/xml/installation.xml	(original)
+++ trunk/docs/xml/installation.xml	Fri Apr 11 17:31:30 2008
@@ -1,5 +1,5 @@
 <!-- <!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"> -->
-<!-- $Id: installation.xml,v 1.136.2.6 2007/10/16 09:57:01 justdave%bugzilla.org Exp $ -->
+<!-- $Id: installation.xml,v 1.136.2.12 2008/02/24 19:31:07 lpsolit%gmail.com Exp $ -->
 <chapter id="installing-bugzilla">
   <title>Installing Bugzilla</title>
 
@@ -468,12 +468,6 @@
           </para>
         </listitem>
 
-        <listitem>
-          <para>
-            Apache::DBI
-            (&min-apache-dbi-ver;) for mod_perl2
-          </para>
-        </listitem>
       </orderedlist>
       </para>
 
@@ -579,7 +573,8 @@
         <para>The PatchReader module is only required if you want to use
         Patch Viewer, a
         Bugzilla feature to show code patches in your web browser in a more
-        readable form.
+        readable form. For more information on Patch Viewer, see
+        <xref linkend="param-patchviewer"/>.
         </para>
       </section>
     </section>
@@ -650,13 +645,9 @@
       <para>Bugzilla also requires a more up-to-date version of the CGI
       perl module to be installed, version &min-mp-cgi-ver; as opposed to &min-cgi-ver;
       </para>
-      
-      <para>Finally, Bugzilla also requires <literal>Apache::DBI</literal>
-      (&min-apache-dbi-ver;) to be installed as well.</para>
     </section>
   </section>
   
-  
   <section id="configuration">
     <title>Configuration</title>
 
@@ -1057,14 +1048,14 @@
                 <para>
                 <filename>checksetup.pl</filename> can set tighter permissions
                 on Bugzilla's files and directories if it knows what group the
-                webserver runs as. Find the <computeroutput>Group</computeroutput>
+                web server runs as. Find the <computeroutput>Group</computeroutput>
                 line in <filename>httpd.conf</filename>, place the value found
                 there in the <replaceable>$webservergroup</replaceable> variable
                 in <filename>localconfig</filename>, then rerun
                 <filename>checksetup.pl</filename>.
                 </para>
             </step>
-    
+
             <step>
                 <para>
                 Optional: If Bugzilla does not actually reside in the webspace
@@ -1127,7 +1118,7 @@
 				<para>
 					<filename>checksetup.pl</filename> can set tighter permissions
 					on Bugzilla's files and directories if it knows what group the
-					webserver runs as. Find the <computeroutput>Group</computeroutput>
+					web server runs as. Find the <computeroutput>Group</computeroutput>
 					line in <filename>httpd.conf</filename>, place the value found
 					there in the <replaceable>$webservergroup</replaceable> variable
 					in <filename>localconfig</filename>, then rerun
@@ -1250,7 +1241,7 @@
             The ActiveState install may have already created an entry for
             .pl files that is limited to <quote>GET,HEAD,POST</quote>. If
             so, this mapping should be <emphasis>removed</emphasis> as
-            Bugzilla's .pl files are not designed to be run via a webserver.
+            Bugzilla's .pl files are not designed to be run via a web server.
           </para>
         </note>
 
@@ -1321,8 +1312,7 @@
       </para>
     </section> 
   </section>
-
-
+  
   <section id="extraconfig">
     <title>Optional Additional Configuration</title>
 
@@ -1489,163 +1479,7 @@
         </para>
       </note>
     </section>
-
-    <section id="patch-viewer">
-      <title>Patch Viewer</title>
-      
-      <para>
-        Patch Viewer is the engine behind Bugzilla's graphical display of
-        code patches. You can integrate this with copies of the
-        <filename>cvs</filename>, <filename>lxr</filename> and
-        <filename>bonsai</filename> tools if you have them, by giving
-        the locations of your installation of these tools in
-        <filename>editparams.cgi</filename>.
-      </para>
         
-      <para>
-        Patch Viewer also optionally will use the 
-        <filename>cvs</filename>, <filename>diff</filename> and 
-        <filename>interdiff</filename>
-        command-line utilities if they exist on the system.
-        Interdiff can be obtained from 
-        <ulink url="http://cyberelk.net/tim/patchutils/"/>.
-        If these programs are not in the system path, you can configure
-        their locations in <filename>localconfig</filename>.
-      </para>
-      
-
-    </section>
-    
-    <section id="bzldap">
-      <title>LDAP Authentication</title>
-
-      <para>LDAP authentication is a module for Bugzilla's plugin 
-      authentication architecture.
-      </para>
-
-      <para>
-      The existing authentication
-      scheme for Bugzilla uses email addresses as the primary user ID, and a
-      password to authenticate that user. All places within Bugzilla where
-      you need to deal with user ID (e.g assigning a bug) use the email
-      address. The LDAP authentication builds on top of this scheme, rather
-      than replacing it. The initial log in is done with a username and
-      password for the LDAP directory. Bugzilla tries to bind to LDAP using
-      those credentials, and if successful, try to map this account to a
-      Bugzilla account. If a  LDAP mail attribute is defined, the value of this
-      attribute is used, otherwise emailsuffix parameter is appended to LDAP
-      username to form a full email address. If an account for this address
-      already exists in your Bugzilla system, it will log in to that account.
-      If no account for that email address exists, one is created at the time
-      of login. (In this case, Bugzilla will attempt to use the "displayName"
-      or "cn" attribute to determine the user's full name.) After
-      authentication, all other user-related tasks are still handled by email
-      address, not LDAP username. You still assign bugs by email address, query
-      on users by email address, etc.
-      </para>
-
-      <caution>
-        <para>Because the Bugzilla account is not created until the first time
-        a user logs in, a user who has not yet logged is unknown to Bugzilla.
-        This means they cannot be used as an assignee or QA contact (default or
-        otherwise), added to any cc list, or any other such operation. One
-        possible workaround is the <filename>bugzilla_ldapsync.rb</filename>
-        script in the
-        <glossterm linkend="gloss-contrib"><filename class="directory">contrib</filename></glossterm> directory. Another possible solution is fixing
-        <ulink url="http://bugzilla.mozilla.org/show_bug.cgi?id=201069";>bug
-        201069</ulink>.
-        </para>
-      </caution>
-
-      <para>Parameters required to use LDAP Authentication:</para>
-
-      <variablelist>
-        <varlistentry id="param-user_verify_class">
-          <term>user_verify_class</term>
-          <listitem>
-            <para>This parameter should be set to <quote>LDAP</quote>
-            <emphasis>only</emphasis> if you will be using an LDAP directory
-            for authentication. If you set this param to <quote>LDAP</quote> but
-            fail to set up the other parameters listed below you will not be
-            able to log back in to Bugzilla one you log out. If this happens
-            to you, you will need to manually edit
-            <filename>data/params</filename> and set user_verify_class to
-            <quote>DB</quote>.
-            </para>
-          </listitem>
-        </varlistentry>
-
-        <varlistentry id="param-LDAPserver">
-          <term>LDAPserver</term>
-          <listitem>
-            <para>This parameter should be set to the name (and optionally the
-            port) of your LDAP server. If no port is specified, it assumes
-            the default LDAP port of 389.
-            </para>
-            <para>Ex. <quote>ldap.company.com</quote>
-             or <quote>ldap.company.com:3268</quote>
-            </para>
-            <para>You can also specify a LDAP URI, so as to use other
-            protocols, such as LDAPS or LDAPI. If port was not specified in
-            the URI, the default is either 389 or 636 for 'LDAP' and 'LDAPS'
-            schemes respectively.
-            </para>
-            <para>Ex. <quote>ldap://ldap.company.com</quote>,
-            <quote>ldaps://ldap.company.com</quote> or
-            <quote>ldapi://%2fvar%2flib%2fldap_sock</quote>
-            </para>
-           </listitem>
-         </varlistentry>
-
-         <varlistentry id="param-LDAPbinddn">
-           <term>LDAPbinddn [Optional]</term>
-           <listitem>
-             <para>Some LDAP servers will not allow an anonymous bind to search
-             the directory. If this is the case with your configuration you
-             should set the LDAPbinddn parameter to the user account Bugzilla
-             should use instead of the anonymous bind.
-             </para>
-             <para>Ex. <quote>cn=default,cn=user:password</quote></para>
-           </listitem>
-         </varlistentry>
-
-         <varlistentry id="param-LDAPBaseDN">
-           <term>LDAPBaseDN</term>
-           <listitem>
-             <para>The LDAPBaseDN parameter should be set to the location in
-             your LDAP tree that you would like to search for email addresses.
-             Your uids should be unique under the DN specified here.
-             </para>
-             <para>Ex. <quote>ou=People,o=Company</quote></para>
-           </listitem>
-         </varlistentry>
-
-         <varlistentry id="param-LDAPuidattribute">
-           <term>LDAPuidattribute</term>
-           <listitem>
-             <para>The LDAPuidattribute parameter should be set to the attribute
-             which contains the unique UID of your users. The value retrieved
-             from this attribute will be used when attempting to bind as the
-             user to confirm their password.
-             </para>
-             <para>Ex. <quote>uid</quote></para>
-           </listitem>
-         </varlistentry>
-
-         <varlistentry id="param-LDAPmailattribute">
-           <term>LDAPmailattribute</term>
-           <listitem>
-             <para>The LDAPmailattribute parameter should be the name of the
-             attribute which contains the email address your users will enter
-             into the Bugzilla login boxes.
-             </para>
-             <para>Ex. <quote>mail</quote></para>
-           </listitem>
-          </varlistentry>
-      </variablelist>
-
-    </section>
-    
     <section id="apache-addtype">
       <title>Serving Alternate Formats with the right MIME type</title>
 
@@ -1750,6 +1584,15 @@
            The following instructions assume that you are using version
            5.8.1 of ActiveState.
           </para>
+
+          <note>
+            <para>
+             These instructions are for 32-bit versions of Windows. If you are
+             using a 64-bit version of Windows, you will need to install 32-bit
+             Perl in order to install the 32-bit modules as described below.
+            </para>
+          </note>
+
         </section>
   
       <section id="win32-perl-modules">
@@ -1759,7 +1602,9 @@
           Bugzilla on Windows requires the same perl modules found in
           <xref linkend="install-perlmodules"/>. The main difference is that
           windows uses <glossterm linkend="gloss-ppm">PPM</glossterm> instead
-          of CPAN.
+          of CPAN. ActiveState provides a GUI to manage Perl modules. We highly
+          recommend that you use it. If you prefer to use ppm from the
+          command-line, type:
         </para>
 
         <programlisting>
@@ -1768,14 +1613,31 @@
 
         <para>
           The best source for the Windows PPM modules needed for Bugzilla
-          is probably the Bugzilla Test Server (aka 'Landfill'), so 
-          you should add the Landfill package repository as follows:
+          is probably the theory58S website, which you can add to your list
+          of repositories as follows (for Perl 5.8.x):
         </para>
 
         <programlisting>
-<command>ppm repository add landfill http://www.landfill.bugzilla.org/ppm/</command>
+<command>ppm repo add theory58S http://theoryx5.uwinnipeg.ca/ppms/</command>
         </programlisting>
 
+        <para>
+          If you are using Perl 5.10.x, you cannot use the same PPM modules as Perl
+          5.8.x as they are incompatible. In this case, you should add the following
+          repository:
+        </para>
+        <programlisting>
+<command>ppm repo add theory58S http://cpan.uwinnipeg.ca/PPMPackages/10xx/</command>
+        </programlisting>
+
+        <note>
+          <para>
+            In versions prior to 5.8.8 build 819 of PPM the command is 
+            <programlisting>
+<command>ppm repository add theory58S http://theoryx5.uwinnipeg.ca/ppms/</command>
+            </programlisting>
+          </para>
+        </note>
         <note>
           <para>
             The PPM repository stores modules in 'packages' that may have
@@ -1872,19 +1734,20 @@
       <section id="macosx-libraries">
         <title>Libraries &amp; Perl Modules on Mac OS X</title>
 
-        <para>Apple did not include the GD library with Mac OS X. Bugzilla
+        <para>Apple does not include the GD library with Mac OS X. Bugzilla
         needs this for bug graphs.</para>
 
-        <para>You can install it using a program called
-        Fink, which is similar in nature to the CPAN installer, but installs
-        common GNU utilities. Fink is available from
-        <ulink url="http://sourceforge.net/projects/fink/"/>.</para>
+        <para>You can use DarwinPorts (<ulink url="http://darwinports.com/"/>)
+        or Fink (<ulink url="http://sourceforge.net/projects/fink/"/>), both
+        of which are similar in nature to the CPAN installer, but install
+        common unix programs.</para>
 
-        <para>Follow the instructions for setting up Fink. Once it's installed,
-        you'll want to use it to install the <filename>gd2</filename> package.
+        <para>Follow the instructions for setting up DarwinPorts or Fink.
+        Once you have one installed, you'll want to use it to install the
+        <filename>gd2</filename> package.
         </para>
 
-        <para>It will prompt you for a number of dependencies, type 'y' and hit
+        <para>Fink will prompt you for a number of dependencies, type 'y' and hit
         enter to install all of the dependencies and then watch it work. You will
         then be able to use <glossterm linkend="gloss-cpan">CPAN</glossterm> to
         install the GD Perl module.
@@ -1905,9 +1768,10 @@
           </para>
         </note>
 
-        <para>Also available via Fink is <filename>expat</filename>. After using
-        fink to install the expat package you will be able to install
-        XML::Parser using CPAN. There is one caveat. Unlike recent versions of
+        <para>Also available via DarwinPorts and Fink is
+        <filename>expat</filename>. After installing the expat package, you
+        will be able to install XML::Parser using CPAN. If you use fink, there
+        is one caveat. Unlike recent versions of
         the GD module, XML::Parser doesn't prompt for the location of the
         required libraries. When using CPAN, you will need to use the following
         command sequence:

Modified: trunk/docs/xml/modules.xml
==============================================================================
--- trunk/docs/xml/modules.xml	(original)
+++ trunk/docs/xml/modules.xml	Fri Apr 11 17:31:30 2008
@@ -24,15 +24,13 @@
         a 'make' utility.  The <command>nmake</command> utility provided with
         Microsoft Visual C++ may be used.  As an alternative, there is a
         utility called <command>dmake</command> available from CPAN which is
-        written entirely in Perl. The majority of the links given below, however,
-        are to pre-compiled versions of the modules, which can be installed
-        on Windows simply by issuing the following command once you have
-        downloaded the PPD file (which may be packaged within a ZIP file):
+        written entirely in Perl.
       </para>
       <para>
-        <screen>
-          <prompt>&gt;</prompt> ppm install &lt;filename.ppd&gt;
-        </screen>
+        As described in <xref linkend="modules-manual-download" />, however, most
+        packages already exist and are available from ActiveState or theory58S.
+        We highly recommend that you install them using the ppm GUI available with
+        ActiveState and to add the theory58S repository to your list of repositories.
       </para>
     </note>
   </section>
@@ -43,9 +41,11 @@
     <note>
       <para>
         Running Bugzilla on Windows requires the use of ActiveState
-        Perl 5.8.1 or higher. Some modules already exist in the core
-        distribution of ActiveState Perl so no PPM link is given.
-        (This is noted where it occurs.)
+        Perl 5.8.1 or higher. Many modules already exist in the core
+        distribution of ActiveState Perl. Additional modules can be downloaded
+        from <ulink url="http://theoryx5.uwinnipeg.ca/ppms/"; /> if you use
+        Perl 5.8.x or from <ulink url="http://cpan.uwinnipeg.ca/PPMPackages/10xx/"; />
+        if you use Perl 5.10.x.
       </para>
     </note>
 
@@ -53,7 +53,6 @@
       CGI:
       <literallayout>
         CPAN Download Page: <ulink url="http://search.cpan.org/dist/CGI.pm/"/>
-        PPM Download Link: Part of core distribution.
         Documentation: <ulink url="http://perldoc.perl.org/CGI.html"/>
       </literallayout>
     </para>
@@ -62,7 +61,6 @@
       Data-Dumper:
       <literallayout>
         CPAN Download Page: <ulink url="http://search.cpan.org/dist/Data-Dumper/"/>
-        PPM Download Page: Part of core distribution.
         Documentation: <ulink url="http://search.cpan.org/dist/Data-Dumper/Dumper.pm"/>
       </literallayout>
     </para>
@@ -71,7 +69,6 @@
       Date::Format (part of TimeDate):
       <literallayout>
         CPAN Download Page: <ulink url="http://search.cpan.org/dist/TimeDate/"/>
-        PPM Download Link: <ulink url="http://landfill.bugzilla.org/ppm/TimeDate.ppd"/>
         Documentation: <ulink url="http://search.cpan.org/dist/TimeDate/lib/Date/Format.pm"/>
       </literallayout>
     </para>
@@ -80,7 +77,6 @@
       DBI:
       <literallayout>
         CPAN Download Page: <ulink url="http://search.cpan.org/dist/DBI/"/>
-        PPM Download Link: <ulink url="http://landfill.bugzilla.org/ppm/DBI.ppd"/>
         Documentation: <ulink url="http://dbi.perl.org/docs/"/>
       </literallayout>
     </para>
@@ -89,7 +85,6 @@
       DBD::mysql:
       <literallayout>
         CPAN Download Page: <ulink url="http://search.cpan.org/dist/DBD-mysql/"/>
-        PPM Download Link: <ulink url="http://landfill.bugzilla.org/ppm/DBD-mysql.ppd"/>
         Documentation: <ulink url="http://search.cpan.org/dist/DBD-mysql/lib/DBD/mysql.pm"/>
       </literallayout>
     </para>
@@ -98,7 +93,6 @@
       DBD::Pg:
       <literallayout>
         CPAN Download Page: <ulink url="http://search.cpan.org/dist/DBD-Pg/"/>
-        PPM Download Link: <ulink url="http://theoryx5.uwinnipeg.ca/ppms/x86/DBD-Pg.tar.gz"/>
         Documentation: <ulink url="http://search.cpan.org/dist/DBD-Pg/Pg.pm"/>
       </literallayout>
     </para>
@@ -107,7 +101,6 @@
       File::Spec:
       <literallayout>
         CPAN Download Page: <ulink url="http://search.cpan.org/dist/File-Spec/"/>
-        PPM Download Page: Part of core distribution.
         Documentation: <ulink url="http://perldoc.perl.org/File/Spec.html"/>
       </literallayout>
     </para>
@@ -116,7 +109,6 @@
       Template-Toolkit:
       <literallayout>
         CPAN Download Page: <ulink url="http://search.cpan.org/dist/Template-Toolkit/"/>
-        PPM Download Link: <ulink url="http://landfill.bugzilla.org/ppm/Template-Toolkit.ppd"/>
         Documentation: <ulink url="http://www.template-toolkit.org/docs.html"/>
       </literallayout>
     </para>
@@ -125,7 +117,6 @@
       GD:
       <literallayout>
         CPAN Download Page: <ulink url="http://search.cpan.org/dist/GD/"/>
-        PPM Download Link: <ulink url="http://landfill.bugzilla.org/ppm/GD.ppd"/>
         Documentation: <ulink url="http://search.cpan.org/dist/GD/GD.pm"/>
       </literallayout>
     </para>
@@ -134,7 +125,6 @@
       Template::Plugin::GD:
       <literallayout>
        CPAN Download Page: <ulink url="http://search.cpan.org/dist/Template-GD/"; />
-       PPM Download Link:  (Just install Template-Toolkit using the instructions below)
        Documentation: <ulink url="http://www.template-toolkit.org/docs/aqua/Modules/index.html"; />
       </literallayout>
     </para>
@@ -143,7 +133,6 @@
       MIME::Parser (part of MIME-tools):
       <literallayout>
         CPAN Download Page: <ulink url="http://search.cpan.org/dist/MIME-tools/"/>
-        PPM Download Link: <ulink url="http://ppm.activestate.com/PPMPackages/zips/8xx-builds-only/Windows/MIME-tools-5.411a.zip"/>
         Documentation: <ulink url="http://search.cpan.org/dist/MIME-tools/lib/MIME/Parser.pm"/>
       </literallayout>
     </para>
@@ -157,7 +146,6 @@
       Chart::Base:
       <literallayout>
         CPAN Download Page: <ulink url="http://search.cpan.org/dist/Chart/"/>
-        PPM Download Page: <ulink url="http://landfill.bugzilla.org/ppm/Chart.ppd"/>
         Documentation: <ulink url="http://search.cpan.org/dist/Chart/Chart.pod"/>
       </literallayout>
     </para>
@@ -166,7 +154,6 @@
       GD::Graph:
       <literallayout>
         CPAN Download Page: <ulink url="http://search.cpan.org/dist/GDGraph/"/>
-        PPM Download Link: <ulink url="http://landfill.bugzilla.org/ppm/GDGraph.ppd"/>
         Documentation: <ulink url="http://search.cpan.org/dist/GDGraph/Graph.pm"/>
       </literallayout>
     </para>
@@ -175,7 +162,6 @@
       GD::Text::Align (part of GD::Text::Util):
       <literallayout>
         CPAN Download Page: <ulink url="http://search.cpan.org/dist/GDTextUtil/"/>
-        PPM Download Page: <ulink url="http://landfill.bugzilla.org/ppm/GDTextUtil.ppd"/>
         Documentation: <ulink url="http://search.cpan.org/dist/GDTextUtil/Text/Align.pm"/>
       </literallayout>
     </para>
@@ -184,7 +170,6 @@
       XML::Twig:
       <literallayout>
         CPAN Download Page: <ulink url="http://search.cpan.org/dist/XML-Twig/"/>
-        PPM Download Link: <ulink url="http://ppm.activestate.com/PPMPackages/zips/8xx-builds-only/Windows/XML-Twig-3.22.zip"/>
         Documentation: <ulink url="http://standards.ieee.org/resources/spasystem/twig/twig_stable.html"/>
       </literallayout>
     </para>
@@ -193,7 +178,6 @@
       PatchReader:
       <literallayout>
         CPAN Download Page: <ulink url="http://search.cpan.org/author/JKEISER/PatchReader/"/>
-        PPM Download Link: <ulink url="http://landfill.bugzilla.org/ppm/PatchReader.ppd"/>
         Documentation: <ulink url="http://www.johnkeiser.com/mozilla/Patch_Viewer.html"/>
       </literallayout>
     </para>
@@ -202,7 +186,6 @@
       Image::Magick:
       <literallayout>
         CPAN Download Page: <ulink url="http://search.cpan.org/dist/PerlMagick/"/>
-        PPM Download Link: Included in Windows binary package.
         Documentation: <ulink url="http://www.imagemagick.org/script/resources.php"/>
       </literallayout>
     </para>

Modified: trunk/docs/xml/using.xml
==============================================================================
--- trunk/docs/xml/using.xml	(original)
+++ trunk/docs/xml/using.xml	Fri Apr 11 17:31:30 2008
@@ -452,17 +452,26 @@
       <section id="pronouns">
         <title>Pronoun Substitution</title>
         <para>
-          Sometimes, a query needs to compare a field containing
-          a user's ID (such as ReportedBy) with 
-          a user's ID (such as the user running the query or the user
-          to whom each bug is assigned). When the operator is either 
-          "equals" or "notequals", the value can be "%reporter%", 
-          "%assignee%", "%qacontact%", or "%user%."  The user pronoun
+          Sometimes, a query needs to compare a user-related field
+          (such as ReportedBy) with a role-specific user (such as the
+          user running the query or the user to whom each bug is assigned).
+          When the operator is either "equals" or "notequals", the value
+          can be "%reporter%", "%assignee%", "%qacontact%", or "%user%".
+          The user pronoun
           refers to the user who is executing the query or, in the case
           of whining reports, the user who will be the recipient
           of the report. The reporter, assignee, and qacontact
           pronouns refer to the corresponding fields in the bug.
         </para>
+        <para>
+          Boolean charts also let you type a group name in any user-related
+          field if the operator is either "equals", "notequals" or "anyexact".
+          This will let you query for any member belonging (or not) to the
+          specified group. The group name must be entered following the
+          "%group.foo%" syntax, where "foo" is the group name.
+          So if you are looking for bugs reported by any user being in the
+          "editbugs" group, then you can type "%group.editbugs%".
+        </para>
       </section>
       <section id="negation">
         <title>Negation</title>
@@ -567,6 +576,16 @@
       </para>
     </section>
 
+    <section id="casesensitivity">
+      <title>Case Sensitivity in Searches</title>
+      <para>
+      Bugzilla queries are case-insensitive and accent-insensitive, when
+      used with MySQL databases. When using Bugzilla with
+      PostgreSQL, however, some queries are case-sensitive. This is due to
+      the way PostgreSQL handles case and accent sensitivity.
+      </para>
+    </section>
+
     <section id="list">
       <title>Bug Lists</title>
 
@@ -1014,6 +1033,15 @@
       </para>
     </section>
 
+    <section id="comment-wrapping">
+      <title>Server-Side Comment Wrapping</title>
+      <para>
+      Bugzilla stores comments unwrapped and wraps them at display time. This
+      ensures proper wrapping in all browsers. Lines beginning with the ">" 
+      character are assumed to be quotes, and are not wrapped.
+      </para>
+    </section>
+
     <section id="dependencytree">
       <title>Dependency Tree</title>
 
@@ -1064,69 +1092,75 @@
   <section id="userpreferences">
     <title>User Preferences</title>
 
-    <para>Once you have logged in, you can customize various aspects of
-    Bugzilla via the "Edit prefs" link in the page footer.
-    The preferences are split into three tabs:</para>
-
-    <section id="accountpreferences" xreflabel="Account Preferences">
-      <title>Account Preferences</title>
-
-      <para>On this tab, you can change your basic account information,
-      including your password, email address and real name. For security
-      reasons, in order to change anything on this page you must type your
-      <emphasis>current</emphasis>
-      password into the
-      <quote>Password</quote>
-      field at the top of the page.
-      If you attempt to change your email address, a confirmation
-      email is sent to both the old and new addresses, with a link to use to
-      confirm the change. This helps to prevent account hijacking.</para>
-    </section>
+    <para>
+    Once logged in, you can customize various aspects of
+    Bugzilla via the "Preferences" link in the page footer.
+    The preferences are split into five tabs:</para>
 
     <section id="generalpreferences" xreflabel="General Preferences">
       <title>General Preferences</title>
 
       <para>
-        This tab allows you to change several Bugzilla behavior.
+        This tab allows you to change several default settings of Bugzilla.
       </para>
 
       <itemizedlist spacing="compact">
         <listitem>
           <para>
+            Bugzilla's general appearance (skin) - select which skin to use.
+            Bugzilla supports adding custom skins.
+          </para>
+        </listitem>
+        <listitem>
+          <para>
             Field separator character for CSV files -
-            This controls separator character used in CSV formatted Bug List.
+            Select between a comma and semi-colon for exported CSV bug lists.
           </para>
         </listitem>
         <listitem>
           <para>
-            After changing bugs - This controls which bugs or no bugs
-            are shown in the page after you changed bugs.
-            You can select the bug you've changed this time, or the next
-            bug of the list.
+            Automatically add me to the CC list of bugs I change - set default
+            behavior of CC list. Options include "Always", "Never", and "Only
+            if I have no role on them".
           </para>
         </listitem>
         <listitem>
           <para>
-            Add individual bugs to saved searches - this controls
-            whether you can add individual bugs to saved searches
-            or you can't.
+            Language used in email - select which language email will be sent in,
+            from the list of available languages.
+          </para>
+        </listitem>
+        <listitem>
+          <para>
+            After changing a bug - This controls what page is displayed after
+            changes to a bug are submitted. The options include to show the bug
+            just modified, to show the next bug in your list, or to do nothing.
+          </para>
+        </listitem>
+        <listitem>
+          <para>
+            Enable tags for bugs - turn bug tagging on or off.
           </para>
         </listitem>
         <listitem>
           <para>
             When viewing a bug, show comments in this order -
-            This controls the order of comments, you can select below:
-            <simplelist>
-              <member>Initial description, comment 1, comment 2, ...</member>
-              <member>Initial description, last comment, ..., comment 2, comment 1.</member>
-              <member>Initial last comment, ..., comment 2, comment 1, description.</member>
-            </simplelist>
+            controls the order of comments. Options include "Oldest
+            to Newest", "Newest to Oldest" and "Newest to Oldest, but keep the
+            bug description at the top".
+          </para>
+        </listitem>
+        <listitem>
+          <para>
+            Show a quip at the top of each bug list - controls
+            whether a quip will be shown on the Bug list page.
           </para>
         </listitem>
         <listitem>
           <para>
-            Show a quip at the top of each bug list - This controls
-            whether a quip will be shown on the Bug list page or not.
+            Zoom textareas large when in use (requires JavaScript) - enable or
+            disable the automatic expanding of text areas when  text is being
+            entered into them.
           </para>
         </listitem>
       </itemizedlist>
@@ -1136,31 +1170,8 @@
       <title>Email Preferences</title>
 
       <para>
-        This tab controls the amount of email Bugzilla sends you.
-      </para>
-
-      <para>
-        The first item on this page is marked <quote>Users to watch</quote>.
-        When you enter one or more comma-delineated user accounts (usually email
-        addresses) into the text entry box, you will receive a copy of all the
-        bugmail those users are sent (security settings permitting).
-        This powerful functionality enables seamless transitions as developers
-        change projects or users go on holiday.
-      </para>
-
-      <note>
-        <para>
-          The ability to watch other users may not be available in all
-          Bugzilla installations. If you don't see this feature, and feel
-          that you need it, speak to your administrator.
-        </para>
-      </note>
-
-      <para>
-        Each user listed in the <quote>Users watching you</quote> field
-        has you listed in their <quote>Users to watch</quote> list
-        and can get bugmail according to your relationship to the bug and
-        their <quote>Field/recipient specific options</quote> setting.
+        This tab allows you to enable or disable email notification on
+        specific events.
       </para>
 
       <para>
@@ -1173,15 +1184,24 @@
 
       <note>
         <para>
-          Your Bugzilla administrator can stop a user from receiving
-          bugmail by adding the user's name to the 
-          <filename>data/nomail</filename> file. This is a drastic step
+          A Bugzilla administrator can stop a user from receiving
+          bugmail by clicking the <quote>Bugmail Disabled</quote> checkbox
+          when editing the user account. This is a drastic step
           best taken only for disabled accounts, as it overrides 
           the user's individual mail preferences.
         </para>
       </note>
   
       <para>
+        There are two global options -- <quote>Email me when someone
+        asks me to set a flag</quote> and <quote>Email me when someone
+        sets a flag I asked for</quote>. These define how you want to
+        receive bugmail with regards to flags. Their use is quite
+        straightforward; enable the checkboxes if you want Bugzilla to
+        send you mail under either of the above conditions.
+      </para>
+
+      <para>
         If you'd like to set your bugmail to something besides
         'Completely ON' and 'Completely OFF', the
         <quote>Field/recipient specific options</quote> table
@@ -1231,7 +1251,6 @@
         </listitem>
       </itemizedlist>
 
-
       <note>
         <para>
           Some columns may not be visible for your installation, depending
@@ -1264,31 +1283,224 @@
       </note>
 
       <para>
-        Two items not in the table (<quote>Email me when someone
-        asks me to set a flag</quote> and <quote>Email me when someone
-        sets a flag I asked for</quote>) define how you want to
-        receive bugmail with regards to flags. Their use is quite
-        straightforward; enable the checkboxes if you want Bugzilla to
-        send you mail under either of the above conditions.
+        Bugzilla has a feature called <quote>Users Watching</quote>.
+        When you enter one or more comma-delineated user accounts (usually email
+        addresses) into the text entry box, you will receive a copy of all the
+        bugmail those users are sent (security settings permitting).
+        This powerful functionality enables seamless transitions as developers
+        change projects or users go on holiday.
+      </para>
+
+      <note>
+        <para>
+          The ability to watch other users may not be available in all
+          Bugzilla installations. If you don't see this feature, and feel
+          that you need it, speak to your administrator.
+        </para>
+      </note>
+
+      <para>
+        Each user listed in the <quote>Users watching you</quote> field
+        has you listed in their <quote>Users to watch</quote> list
+        and can get bugmail according to your relationship to the bug and
+        their <quote>Field/recipient specific options</quote> setting.
       </para>
 
+    </section>
+
+    <section id="savedsearches" xreflabel="Saved Searches">
+      <title>Saved Searches</title>
       <para>
-        By default, Bugzilla sends out email regardless of who made the
-        change... even if you were the one responsible for generating
-        the email in the first place. If you don't care to receive bugmail
-        from your own changes, check the box marked <quote>Only email me
-        reports of changes made by other people</quote>.
+      On this tab you can view and run any Saved Searches that you have
+      created, and also any Saved Searches that other members of the group
+      defined in the "querysharegroup" parameter have shared.
+      Saved Searches can be added to the page footer from this screen.
+      If somebody is sharing a Search with a group she or he is allowed to
+      <link linkend="groups">assign users to</link>, the sharer may opt to have
+      the Search show up in the footer of the group's direct members by default.
       </para>
+    </section>
+
+    <section id="accountpreferences" xreflabel="Name and Password">
+      <title>Name and Password</title>
 
+      <para>On this tab, you can change your basic account information,
+      including your password, email address and real name. For security
+      reasons, in order to change anything on this page you must type your
+      <emphasis>current</emphasis> password into the <quote>Password</quote>
+      field at the top of the page.
+      If you attempt to change your email address, a confirmation
+      email is sent to both the old and new addresses, with a link to use to
+      confirm the change. This helps to prevent account hijacking.</para>
     </section>
 
     <section id="permissionsettings">
       <title>Permissions</title>
       
-      <para>This is a purely informative page which outlines your current
-      permissions on this installation of Bugzilla - what product groups you
-      are in, and whether you can edit bugs or perform various administration
-      functions.</para>
+      <para>
+      This is a purely informative page which outlines your current
+      permissions on this installation of Bugzilla.
+      </para>
+
+      <para>
+      A complete list of permissions is below. Only users with 
+      <emphasis>editusers</emphasis> privileges can change the permissions 
+      of other users.
+      </para>
+
+      <variablelist>
+        <varlistentry>
+          <term>
+            admin
+          </term>
+          <listitem>
+            <para> 
+             Indicates user is an Administrator.
+            </para>
+          </listitem>
+        </varlistentry>
+
+        <varlistentry>
+          <term>
+            bz_canusewhineatothers
+          </term>
+          <listitem>
+            <para> 
+             Indicates user can configure whine reports for other users.
+            </para>
+          </listitem>
+        </varlistentry>
+
+        <varlistentry>
+          <term>
+             bz_canusewhines
+          </term>
+          <listitem>
+            <para> 
+             Indicates user can configure whine reports for self.
+            </para>
+          </listitem>
+        </varlistentry>	 	
+ 
+        <varlistentry>
+          <term>
+             bz_sudoers
+          </term>
+          <listitem>
+            <para> 
+             Indicates user can perform actions as other users.
+            </para>
+          </listitem>
+        </varlistentry>	
+
+        <varlistentry>
+          <term>
+             bz_sudo_protect
+          </term>
+          <listitem>
+            <para> 
+             Indicates user can not be impersonated by other users.
+            </para>
+          </listitem>
+        </varlistentry>
+
+        <varlistentry>
+          <term>
+             canconfirm
+          </term>
+          <listitem>
+            <para> 
+             Indicates user can confirm a bug or mark it a duplicate.
+            </para>
+          </listitem>
+        </varlistentry>
+
+        <varlistentry>
+          <term>
+             creategroups
+          </term>
+          <listitem>
+            <para> 
+             Indicates user can create and destroy groups.
+            </para>
+          </listitem>
+        </varlistentry>
+
+        <varlistentry>
+          <term>
+             editbugs
+          </term>
+          <listitem>
+            <para> 
+             Indicates user can edit all bug fields.
+            </para>
+          </listitem>
+        </varlistentry>
+
+        <varlistentry>
+          <term>
+             editclassifications
+          </term>
+          <listitem>
+            <para> 
+             Indicates user can create, destroy, and edit classifications.
+            </para>
+          </listitem>
+        </varlistentry>
+
+        <varlistentry>
+          <term>
+             editcomponents
+          </term>
+          <listitem>
+            <para> 
+             Indicates user can create, destroy, and edit components.
+            </para>
+          </listitem>
+        </varlistentry>
+ 
+        <varlistentry>
+          <term>
+             editkeywords
+          </term>
+          <listitem>
+            <para> 
+             Indicates user can create, destroy, and edit keywords.
+            </para>
+          </listitem>
+        </varlistentry>
+
+        <varlistentry>
+          <term>
+             editusers
+          </term>
+          <listitem>
+            <para> 
+             Indicates user can edit or disable users.
+            </para>
+          </listitem>
+        </varlistentry>
+	
+        <varlistentry>
+          <term>
+             tweakparams
+          </term>
+          <listitem>
+            <para> 
+             Indicates user can change Parameters.
+            </para>
+          </listitem>
+        </varlistentry>
+
+      </variablelist>
+
+       <note>
+        <para>
+        For more information on how permissions work in Bugzilla (i.e. who can
+        change what), see  <xref linkend="cust-change-permissions"/>. 
+        </para>
+       </note>
+
     </section>
   </section>
   

Modified: trunk/editproducts.cgi
==============================================================================
--- trunk/editproducts.cgi	(original)
+++ trunk/editproducts.cgi	Fri Apr 11 17:31:30 2008
@@ -939,10 +939,7 @@
                 my ($who, $id) = (@$vote);
                 # If some votes are removed, RemoveVotes() returns a list
                 # of messages to send to voters.
-                my $msgs =
-                    RemoveVotes($id, $who, "The rules for voting on this product " .
-                                           "has changed;\nyou had too many votes " .
-                                           "for a single bug.");
+                my $msgs = RemoveVotes($id, $who, 'votes_too_many_per_bug');
                 foreach my $msg (@$msgs) {
                     MessageToMTA($msg);
                 }
@@ -991,11 +988,7 @@
                 foreach my $bug_id (@$bug_ids) {
                     # RemoveVotes() returns a list of messages to send
                     # in case some voters had too many votes.
-                    my $msgs =
-                        RemoveVotes($bug_id, $who, "The rules for voting on this " .
-                                                   "product has changed; you had " .
-                                                   "too many\ntotal votes, so all " .
-                                                   "votes have been removed.");
+                    my $msgs = RemoveVotes($bug_id, $who, 'votes_too_many_per_user');
                     foreach my $msg (@$msgs) {
                         MessageToMTA($msg);
                     }

Modified: trunk/editusers.cgi
==============================================================================
--- trunk/editusers.cgi	(original)
+++ trunk/editusers.cgi	Fri Apr 11 17:31:30 2008
@@ -585,9 +585,6 @@
     }
 
     # 2) Whines
-    my $sth_whineidFromSchedules = $dbh->prepare(
-           qq{SELECT eventid FROM whine_schedules
-              WHERE mailto = ? AND mailto_type = ?});
     my $sth_whineidFromEvents = $dbh->prepare(
            'SELECT id FROM whine_events WHERE owner_userid = ?');
     my $sth_deleteWhineEvent = $dbh->prepare(
@@ -597,12 +594,8 @@
     my $sth_deleteWhineSchedule = $dbh->prepare(
            'DELETE FROM whine_schedules WHERE eventid = ?');
 
-    $sth_whineidFromSchedules->execute($otherUserID, MAILTO_USER);
-    while ($id = $sth_whineidFromSchedules->fetchrow_array()) {
-        $sth_deleteWhineQuery->execute($id);
-        $sth_deleteWhineSchedule->execute($id);
-        $sth_deleteWhineEvent->execute($id);
-    }
+    $dbh->do('DELETE FROM whine_schedules WHERE mailto = ? AND mailto_type = ?',
+             undef, ($otherUserID, MAILTO_USER));
 
     $sth_whineidFromEvents->execute($otherUserID);
     while ($id = $sth_whineidFromEvents->fetchrow_array()) {

Modified: trunk/email_in.pl
==============================================================================
--- trunk/email_in.pl	(original)
+++ trunk/email_in.pl	Fri Apr 11 17:31:30 2008
@@ -54,25 +54,6 @@
 # in a message. RFC-compliant mailers use this.
 use constant SIGNATURE_DELIMITER => '-- ';
 
-# These fields must all be defined or post_bug complains. They don't have
-# to have values--they just have to be defined. There's not yet any
-# way to require custom fields have values, for enter_bug, so we don't
-# have to worry about those yet.
-use constant REQUIRED_ENTRY_FIELDS => qw(
-    reporter
-    short_desc
-    product
-    component
-    version
-
-    assigned_to
-    rep_platform
-    op_sys
-    priority
-    bug_severity
-    bug_file_loc
-);
-
 # Fields that must be defined during process_bug. They *do* have to
 # have values. The script will grab their values from the current
 # bug object, if they're not specified.
@@ -91,6 +72,7 @@
     short_desc
     reporter_accessible
     cclist_accessible
+    qa_contact
 );
 
 # $input_email is a global so that it can be used in die_handler.
@@ -178,15 +160,6 @@
 
     debug_print('Posting a new bug...');
 
-    $fields{'rep_platform'} ||= Bugzilla->params->{'defaultplatform'};
-    $fields{'op_sys'}   ||= Bugzilla->params->{'defaultopsys'};
-    $fields{'priority'} ||= Bugzilla->params->{'defaultpriority'};
-    $fields{'bug_severity'} ||= Bugzilla->params->{'defaultseverity'};
-
-    foreach my $field (REQUIRED_ENTRY_FIELDS) {
-        $fields{$field} ||= '';
-    }
-
     my $cgi = Bugzilla->cgi;
     foreach my $field (keys %fields) {
         $cgi->param(-name => $field, -value => $fields{$field});
@@ -217,15 +190,22 @@
     if (my $status = $fields{'bug_status'}) {
         $fields{'knob'} = 'confirm' if $status =~ /NEW/i;
         $fields{'knob'} = 'accept'  if $status =~ /ASSIGNED/i;
-        $fields{'knob'} = 'clearresolution' if $status =~ /REOPENED/i;
+        $fields{'knob'} = 'reopen' if $status =~ /REOPENED/i;
+        $fields{'knob'} = 'resolve' if $status =~ /RESOLVED/i;
         $fields{'knob'} = 'verify'  if $status =~ /VERIFIED/i;
         $fields{'knob'} = 'close'   if $status =~ /CLOSED/i;
+        # Only @bug_status = RESOLVED can have a @resolution.
+        delete $fields{'resolution'} if $status !~ /RESOLVED/i;
     }
     if ($fields{'dup_id'}) {
         $fields{'knob'} = 'duplicate';
     }
     if ($fields{'resolution'}) {
-        $fields{'knob'} = 'resolve';
+        # If @bug_status is defined and we come here, then we know
+        # @bug_status = RESOLVED as the resolution would be ignored otherwise.
+        # If bug_status is undefined, then all we want to do is to change
+        # the resolution of the bug, leaving its status alone.
+        $fields{'knob'} = 'change_resolution' unless $fields{'bug_status'};
     }
 
     # Make sure we don't get prompted if we have to change the default
@@ -236,6 +216,7 @@
 
     foreach my $field (REQUIRED_PROCESS_FIELDS) {
         my $value = $bug->$field;
+        $value = $value->login if ($field eq 'qa_contact' && $value);
         if (ref $value) {
             $value = join(',', @$value);
         }
@@ -297,7 +278,8 @@
     foreach my $part (@parts) {
         my $ct = $part->content_type || 'text/plain';
         my $charset = 'iso-8859-1';
-        if ($ct =~ /charset=([^;]+)/) {
+        # The charset may be quoted.
+        if ($ct =~ /charset="?([^;"]+)/) {
             $charset= $1;
         }
         debug_print("Part Content-Type: $ct", 2);
@@ -388,6 +370,11 @@
 my $mail_fields = parse_mail($mail_text);
 
 my $username = $mail_fields->{'reporter'};
+# If emailsuffix is in use, we have to remove it from the email address.
+if (my $suffix = Bugzilla->params->{'emailsuffix'}) {
+    $username =~ s/\Q$suffix\E$//i;
+}
+
 my $user = Bugzilla::User->new({ name => $username })
     || ThrowUserError('invalid_username', { name => $username });
 
@@ -442,9 +429,24 @@
  be included in the bug description.
 
 The C<@> labels can be any valid field name in Bugzilla that can be
-set on C<enter_bug.cgi>. For the list of field names, see the
-C<fielddefs> table in the database. The above example shows the
-minimum fields you B<must> specify.
+set on C<enter_bug.cgi>. For the list of required field names, see 
+L<Bugzilla::WebService::Bug/Create>. Note, that there is some difference
+in the names of the required input fields between web and email interfaces, 
+as listed below:
+
+=over
+
+=item *
+
+C<platform> in web is C<@rep_platform> in email
+
+=item *
+
+C<severity> in web is C<@bug_severity> in email
+
+=back
+
+For the list of all field names, see the C<fielddefs> table in the database. 
 
 The values for the fields can be split across multiple lines, but
 note that a newline will be parsed as a single space, for the value.

Modified: trunk/mod_perl.pl
==============================================================================
--- trunk/mod_perl.pl	(original)
+++ trunk/mod_perl.pl	Fri Apr 11 17:31:30 2008
@@ -28,7 +28,6 @@
 # startup, so we always specify () after using any module in this
 # file.
 
-use Apache::DBI ();
 use Apache2::ServerUtil;
 use Apache2::SizeLimit;
 use ModPerl::RegistryLoader ();
@@ -71,6 +70,9 @@
 
 # Have ModPerl::RegistryLoader pre-compile all CGI scripts.
 my $rl = new ModPerl::RegistryLoader();
+# If we try to do this in "new" it fails because it looks for a 
+# Bugzilla/ModPerl/ResponseHandler.pm
+$rl->{package} = 'Bugzilla::ModPerl::ResponseHandler';
 # Note that $cgi_path will be wrong if somebody puts the libraries
 # in a different place than the CGIs.
 foreach my $file (glob "$cgi_path/*.cgi") {

Modified: trunk/process_bug.cgi
==============================================================================
--- trunk/process_bug.cgi	(original)
+++ trunk/process_bug.cgi	Fri Apr 11 17:31:30 2008
@@ -880,6 +880,8 @@
         $::query .= "$fname = ?";
         my $value = $cgi->param($fname);
         check_field($fname, $value) if ($field->type == FIELD_TYPE_SINGLE_SELECT);
+        $value = Bugzilla::Bug->_check_freetext_field($value)
+          if ($field->type == FIELD_TYPE_FREETEXT);
         trick_taint($value);
         push(@values, $value);
     }
@@ -1099,6 +1101,23 @@
     }
 }
 
+# By default, makes sure that all bugs are in a closed state.
+# If $all_open is true, makes sure that all bugs are open.
+sub check_bugs_resolution {
+    my ($idlist, $all_open) = @_;
+    my $dbh = Bugzilla->dbh;
+
+    my $open_states = join(',', map {$dbh->quote($_)} BUG_STATE_OPEN);
+    # The list has already been validated.
+    $idlist = join(',', @$idlist);
+    my $sql_cond = $all_open ? 'NOT' : '';
+    my $has_unwanted_bugs =
+      $dbh->selectrow_array("SELECT 1 FROM bugs WHERE bug_id IN ($idlist)
+                             AND bug_status $sql_cond IN ($open_states)");
+
+    # If there are unwanted bugs, then the test fails.
+    return !$has_unwanted_bugs;
+}
 
 SWITCH2: for ($cgi->param('knob2')) {
     /^none$/ && do {
@@ -1181,6 +1200,9 @@
         last SWITCH;
     };
     /^clearresolution$/ && CheckonComment( "clearresolution" ) && do {
+        # All bugs must already be open.
+        check_bugs_resolution(\ idlist, 'all_open')
+          || ThrowUserError('resolution_deletion_not_allowed');
         ChangeResolution($bug, '');
         last SWITCH;
     };
@@ -1211,13 +1233,7 @@
         else {
             # You cannot use change_resolution if there is at least
             # one open bug.
-            my $open_states = join(',', map {$dbh->quote($_)} BUG_STATE_OPEN);
-            my $idlist = join(',', @idlist);
-            my $is_open =
-              $dbh->selectrow_array("SELECT 1 FROM bugs WHERE bug_id IN ($idlist)
-                                     AND bug_status IN ($open_states)");
-
-            ThrowUserError('resolution_not_allowed') if $is_open;
+            check_bugs_resolution(\ idlist) || ThrowUserError('resolution_not_allowed');
         }
 
         ChangeResolution($bug, $cgi->param('resolution'));
@@ -1229,10 +1245,16 @@
         last SWITCH;
     };
     /^verify$/ && CheckonComment( "verify" ) && do {
+        check_bugs_resolution(\ idlist)
+          || ThrowUserError('bug_status_not_allowed', {status => 'VERIFIED'});
+
         ChangeStatus('VERIFIED');
         last SWITCH;
     };
     /^close$/ && CheckonComment( "close" ) && do {
+        check_bugs_resolution(\ idlist)
+          || ThrowUserError('bug_status_not_allowed', {status => 'CLOSED'});
+
         # CLOSED bugs should have no time remaining.
         _remove_remaining_time();
 
@@ -1531,7 +1553,8 @@
             "keyworddefs READ", "groups READ", "attachments READ",
             "group_control_map AS oldcontrolmap READ",
             "group_control_map AS newcontrolmap READ",
-            "group_control_map READ", "email_setting READ", "classifications READ");
+            "group_control_map READ", "email_setting READ", "classifications READ",
+            "setting READ", "profile_setting READ");
 
     # It may sound crazy to set %formhash for each bug as $cgi->param()
     # will not change, but %formhash is modified below and we prefer
@@ -2109,9 +2132,7 @@
                 # If some votes have been removed, RemoveVotes() returns
                 # a list of messages to send to voters.
                 # We delay the sending of these messages till tables are unlocked.
-                $msgs = RemoveVotes($id, 0,
-                          "This bug has been moved to a different product");
-
+                $msgs = RemoveVotes($id, 0, 'votes_bug_moved');
                 CheckIfVotedConfirmed($id, $whoid);
             }
 

Modified: trunk/query.cgi
==============================================================================
--- trunk/query.cgi	(original)
+++ trunk/query.cgi	Fri Apr 11 17:31:30 2008
@@ -111,6 +111,7 @@
 # and ignore any multiple values.
 sub PrefillForm {
     my ($buf) = (@_);
+    my $cgi = Bugzilla->cgi;
     $buf = new Bugzilla::CGI($buf);
     my $foundone = 0;
 
@@ -128,6 +129,7 @@
                       "bug_file_loc_type", "status_whiteboard",
                       "status_whiteboard_type", "bug_id",
                       "bugidtype", "keywords", "keywords_type",
+                      "deadlinefrom", "deadlineto",
                       "x_axis_field", "y_axis_field", "z_axis_field",
                       "chart_format", "cumulate", "x_labels_vertical",
                       "category", "subcategory", "name", "newcategory",

Modified: trunk/relogin.cgi
==============================================================================
--- trunk/relogin.cgi	(original)
+++ trunk/relogin.cgi	Fri Apr 11 17:31:30 2008
@@ -158,11 +158,11 @@
 
     # Go ahead and send out the message now
     my $message;
-    $template->process('email/sudo.txt.tmpl', 
-                       { reason => $reason },
-                       \$message);
+    my $mail_template = Bugzilla->template_inner($target_user->settings->{'lang'}->{'value'});
+    $mail_template->process('email/sudo.txt.tmpl', { reason => $reason }, \$message);
+    Bugzilla->template_inner("");
     MessageToMTA($message);
-        
+
     $vars->{'message'} = 'sudo_started';
     $vars->{'target'} = $target_user->login;
     $target = 'global/message.html.tmpl';

Modified: trunk/skins/standard/CVS/Entries
==============================================================================
--- trunk/skins/standard/CVS/Entries	(original)
+++ trunk/skins/standard/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -1,7 +1,6 @@
 D/dependency-tree////
 D/global////
 D/index////
-/IE-fixes.css/1.1/Mon Jan  1 00:11:02 2007//TBUGZILLA-3_0-BRANCH
 /admin.css/1.3/Mon Jan  1 00:11:02 2007//TBUGZILLA-3_0-BRANCH
 /buglist.css/1.11/Mon Jan  1 00:11:02 2007//TBUGZILLA-3_0-BRANCH
 /create_attachment.css/1.1/Mon Jan  1 00:11:02 2007//TBUGZILLA-3_0-BRANCH
@@ -15,4 +14,5 @@
 /show_multiple.css/1.4/Mon Jan  1 00:11:02 2007//TBUGZILLA-3_0-BRANCH
 /summarize-time.css/1.1/Mon Jan  1 00:11:02 2007//TBUGZILLA-3_0-BRANCH
 /voting.css/1.1/Mon Jan  1 00:11:02 2007//TBUGZILLA-3_0-BRANCH
-/global.css/1.31.2.2/Sat Aug 11 20:17:22 2007//TBUGZILLA-3_0-BRANCH
+/IE-fixes.css/1.1.2.1/Fri Apr 11 16:25:52 2008//TBUGZILLA-3_0-BRANCH
+/global.css/1.31.2.4/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH

Modified: trunk/skins/standard/IE-fixes.css
==============================================================================
--- trunk/skins/standard/IE-fixes.css	(original)
+++ trunk/skins/standard/IE-fixes.css	Fri Apr 11 17:31:30 2008
@@ -13,6 +13,11 @@
   * Contributor(s): Marc Schumann <wurblzap gmail com>
   */
 
+.bz_comment_text {
+     white-space: pre;
+     word-wrap: break-word;
+}
+
 #footer #useful-links li {
     padding-bottom: 0.8ex;
 }

Modified: trunk/skins/standard/global.css
==============================================================================
--- trunk/skins/standard/global.css	(original)
+++ trunk/skins/standard/global.css	Fri Apr 11 17:31:30 2008
@@ -244,6 +244,22 @@
     margin-bottom: 2em;
 }
 
+/* The rules for these classes make international text wrap correctly,
+   even for languages like Japanese that have no spaces. */
+.bz_comment_text {
+     font-family: monospace;
+    /* Note that these must all be on separate lines or they stop
+       working in Konqueror. */
+     white-space: pre-wrap;      /* CSS 3 & 2.1 */
+     white-space: -moz-pre-wrap; /* Gecko */
+     white-space: -pre-wrap;     /* Opera 4-6 */
+     white-space: -o-pre-wrap;   /* Opera 7 */
+}
+
+.bz_comment_text {
+     width: 50em;
+}
+
 .bz_comment_head {
     background-color: #e0e0e0;
 }
@@ -255,6 +271,8 @@
 
 span.quote {
     color: #65379c;
+    /* Make quoted text not wrap. */
+    white-space: pre;
 }
 
 table#flags th,
@@ -314,6 +332,22 @@
     padding-left: 1em;
 }
 
+table.attachment_info th {
+    text-align: right;
+    vertical-align: top;
+}
+
+table.attachment_info td {
+    text-align: left;
+    vertical-align: top;
+}
+
+/* Text displayed when the attachment is not viewable by the web browser */
+#noview {
+    text-align: left;
+    vertical-align: middle;
+}
+
 div.user_match {
     margin-bottom: 1em;
 }

Modified: trunk/t/004template.t
==============================================================================
Binary files. No diff available.

Modified: trunk/t/CVS/Entries
==============================================================================
--- trunk/t/CVS/Entries	(original)
+++ trunk/t/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -2,7 +2,6 @@
 /001compile.t/1.15/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
 /002goodperl.t/1.15/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
 /003safesys.t/1.6/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
-/004template.t/1.38/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
 /005no_tabs.t/1.13/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
 /006spellcheck.t/1.5/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
 /007util.t/1.8/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
@@ -11,3 +10,4 @@
 /011pod.t/1.1/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
 /012throwables.t/1.5/Mon Jan  1 00:11:03 2007//TBUGZILLA-3_0-BRANCH
 /009bugwords.t/1.5.2.2/Sat Aug 11 20:17:22 2007//TBUGZILLA-3_0-BRANCH
+/004template.t/1.38.2.1/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH

Modified: trunk/template/en/default/CVS/Entries
==============================================================================
--- trunk/template/en/default/CVS/Entries	(original)
+++ trunk/template/en/default/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -11,9 +11,9 @@
 D/request////
 D/search////
 D/whine////
-/welcome-admin.html.tmpl/1.2/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /index.html.tmpl/1.33.2.4/Sat Aug 11 20:17:23 2007//TBUGZILLA-3_0-BRANCH
 /sidebar.xul.tmpl/1.22.2.1/Sat Aug 11 20:17:23 2007//TBUGZILLA-3_0-BRANCH
 /filterexceptions.pl/1.95.2.1/Sun Sep  2 09:52:05 2007//TBUGZILLA-3_0-BRANCH
 /config.js.tmpl/1.7.2.1/Tue Nov  6 20:18:15 2007//TBUGZILLA-3_0-BRANCH
 /config.rdf.tmpl/1.7.2.2/Tue Nov  6 20:18:15 2007//TBUGZILLA-3_0-BRANCH
+/welcome-admin.html.tmpl/1.2.2.1/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH

Modified: trunk/template/en/default/account/CVS/Entries
==============================================================================
--- trunk/template/en/default/account/CVS/Entries	(original)
+++ trunk/template/en/default/account/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -2,7 +2,7 @@
 D/email////
 D/password////
 D/prefs////
-/cancel-token.txt.tmpl/1.11.2.1/Sun Apr  8 13:11:07 2007//TBUGZILLA-3_0-BRANCH
 /create.html.tmpl/1.10/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /created.html.tmpl/1.7/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /profile-activity.html.tmpl/1.2/Sun Jan 21 15:43:20 2007//TBUGZILLA-3_0-BRANCH
+/cancel-token.txt.tmpl/1.11.2.2/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH

Modified: trunk/template/en/default/account/cancel-token.txt.tmpl
==============================================================================
--- trunk/template/en/default/account/cancel-token.txt.tmpl	(original)
+++ trunk/template/en/default/account/cancel-token.txt.tmpl	Fri Apr 11 17:31:30 2008
@@ -33,7 +33,7 @@
 mistake or someone attempting to break into your [% terms.Bugzilla %] account.
 
 Take a look at the information below and forward this email
-to [% maintainer %] if you suspect foul play.
+to [% Param('maintainer') %] if you suspect foul play.
 
             Token: [% token %]
        Token Type: [% tokentype %]

Modified: trunk/template/en/default/admin/classifications/CVS/Entries
==============================================================================
--- trunk/template/en/default/admin/classifications/CVS/Entries	(original)
+++ trunk/template/en/default/admin/classifications/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -2,8 +2,8 @@
 /del.html.tmpl/1.7/Sun Jan 21 15:43:20 2007//TBUGZILLA-3_0-BRANCH
 /delete.html.tmpl/1.2/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /new.html.tmpl/1.2/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
-/reclassify.html.tmpl/1.7/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /select.html.tmpl/1.7/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /update.html.tmpl/1.2/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /edit.html.tmpl/1.10.2.1/Sun Sep  2 09:52:05 2007//TBUGZILLA-3_0-BRANCH
+/reclassify.html.tmpl/1.7.2.1/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
 D

Modified: trunk/template/en/default/admin/classifications/reclassify.html.tmpl
==============================================================================
--- trunk/template/en/default/admin/classifications/reclassify.html.tmpl	(original)
+++ trunk/template/en/default/admin/classifications/reclassify.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -45,9 +45,9 @@
 
     </tr><tr>
       <td valign="top">Products:</td>
-      <td valign="top">Products</td>
+      <td valign="top">Other Classifications</td>
       <td></td>
-      <td valign="top">[% classification.name FILTER html %] Products</td>
+      <td valign="top">This Classification</td>
 
     </tr><tr>
       <td></td>

Modified: trunk/template/en/default/admin/groups/CVS/Entries
==============================================================================
--- trunk/template/en/default/admin/groups/CVS/Entries	(original)
+++ trunk/template/en/default/admin/groups/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -1,9 +1,9 @@
 /change.html.tmpl/1.2/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /create.html.tmpl/1.8/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /created.html.tmpl/1.1/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
-/delete.html.tmpl/1.10/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /deleted.html.tmpl/1.3/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /edit.html.tmpl/1.11/Sun Jan 21 15:43:20 2007//TBUGZILLA-3_0-BRANCH
 /list.html.tmpl/1.11/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /remove.html.tmpl/1.2/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
+/delete.html.tmpl/1.10.2.1/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
 D

Modified: trunk/template/en/default/admin/groups/delete.html.tmpl
==============================================================================
--- trunk/template/en/default/admin/groups/delete.html.tmpl	(original)
+++ trunk/template/en/default/admin/groups/delete.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -120,10 +120,12 @@
           indicated problems first before you can proceed.</b></p>
   [% END %]
 
-  <p><input type="submit" id="delete" value="Yes, delete">
-  <input type="hidden" name="action" value="delete">
-  <input type="hidden" name="group" value="[% gid FILTER html %]">
-  <input type="hidden" name="token" value="[% token FILTER html %]">
+  <p>
+    <input type="submit" id="delete" value="Yes, delete">
+    <input type="hidden" name="action" value="delete">
+    <input type="hidden" name="group" value="[% gid FILTER html %]">
+    <input type="hidden" name="token" value="[% token FILTER html %]">
+  </p>
 </form>
 
 Go back to the <a href="editgroups.cgi">group list</a>.

Modified: trunk/template/en/default/admin/params/CVS/Entries
==============================================================================
--- trunk/template/en/default/admin/params/CVS/Entries	(original)
+++ trunk/template/en/default/admin/params/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -1,6 +1,5 @@
 /admin.html.tmpl/1.3/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /attachment.html.tmpl/1.3/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
-/auth.html.tmpl/1.1/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /bugchange.html.tmpl/1.3/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /bugfields.html.tmpl/1.3/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /bugmove.html.tmpl/1.2/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
@@ -17,4 +16,5 @@
 /core.html.tmpl/1.5.2.2/Sat Aug 11 20:17:23 2007//TBUGZILLA-3_0-BRANCH
 /mta.html.tmpl/1.9.2.1/Sat Aug 11 20:17:23 2007//TBUGZILLA-3_0-BRANCH
 /query.html.tmpl/1.1.4.2/Sat Aug 11 20:17:23 2007//TBUGZILLA-3_0-BRANCH
+/auth.html.tmpl/1.1.4.1/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
 D

Modified: trunk/template/en/default/admin/params/auth.html.tmpl
==============================================================================
--- trunk/template/en/default/admin/params/auth.html.tmpl	(original)
+++ trunk/template/en/default/admin/params/auth.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -69,10 +69,10 @@
                           </dd>
                           <dt>LDAP</dt>
                           <dd>
-                            LDAP authentication using an LDAP server. This method is
-                            experimental; please see the $terms.Bugzilla documentation for more
-                            information. Using this method requires additional parameters
-                            to be set above.
+                            LDAP authentication using an LDAP server.
+                            Please see the $terms.Bugzilla documentation
+                            for more information. Using this method requires
+                            additional parameters to be set above.
                           </dd>
                         </dl>",
 
@@ -121,4 +121,4 @@
                        "to be created. If this parameter is left blank, no users " _
                        "will be permitted to create their own accounts and all accounts " _
                        "will have to be created by an administrator." }
-%]
\ No newline at end of file
+%]

Modified: trunk/template/en/default/admin/users/CVS/Entries
==============================================================================
--- trunk/template/en/default/admin/users/CVS/Entries	(original)
+++ trunk/template/en/default/admin/users/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -3,6 +3,6 @@
 /list.html.tmpl/1.3/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /listselectvars.html.tmpl/1.1/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /search.html.tmpl/1.4/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
-/userdata.html.tmpl/1.8.2.1/Sat May 12 19:37:52 2007//TBUGZILLA-3_0-BRANCH
-/confirm-delete.html.tmpl/1.15.2.1/Sat Aug 11 20:17:23 2007//TBUGZILLA-3_0-BRANCH
+/confirm-delete.html.tmpl/1.15.2.2/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
+/userdata.html.tmpl/1.8.2.2/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
 D

Modified: trunk/template/en/default/admin/users/confirm-delete.html.tmpl
==============================================================================
--- trunk/template/en/default/admin/users/confirm-delete.html.tmpl	(original)
+++ trunk/template/en/default/admin/users/confirm-delete.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -401,27 +401,15 @@
             will cease along with the deletion of the user account.
           </li>
         [% END %]
-        [% IF whine_events || whine_schedules %]
+        [% IF whine_events %]
           <li>
-            [% otheruser.login FILTER html %]
-            [% IF whine_events %]
-              has scheduled
-              [% IF whine_events == 1 %]
-                a whine
-              [% ELSE %]
-                [%+ whine_events %] whines
-              [% END %]
-            [% END %]
-            [% IF whine_schedules %]
-              [%+ 'and' IF whine_events %]
-              is on the receiving end of
-              [% IF whine_schedules == 1 %]
-                a whine
-              [% ELSE %]
-                [%+ whine_schedules %] whines
-              [% END %]
+            [% otheruser.login FILTER html %] has scheduled
+            [% IF whine_events == 1 %]
+              a whine
+            [% ELSE %]
+              [%+ whine_events %] whines
             [% END %].
-            [% IF whine_events + whine_schedules == 1 %]
+            [% IF whine_events == 1 %]
               This whine
             [% ELSE %]
               These whines
@@ -429,6 +417,18 @@
             will be deleted along with the user account.
           </li>
         [% END %]
+        [% IF whine_schedules %]
+          <li>
+            [% otheruser.login FILTER html %] is on the receiving end of
+            [% IF whine_schedules == 1 %]
+              a whine
+            [% ELSE %]
+              [%+ whine_schedules %] whines
+            [% END %].
+            The corresponding schedules will be deleted along with the user account,
+            but the whines themselves will be left unaltered.
+          </li>
+        [% END %]
       </ul>
     </div>
     [% display_warning = 1 %]

Modified: trunk/template/en/default/admin/users/userdata.html.tmpl
==============================================================================
--- trunk/template/en/default/admin/users/userdata.html.tmpl	(original)
+++ trunk/template/en/default/admin/users/userdata.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -31,7 +31,7 @@
         [% IF !otheruser.groups.bz_sudo_protect %]
           <br />
           <a href="relogin.cgi?action=prepare-sudo&amp;target_login=
-          [%- otheruser.login FILTER html %]">Impersonate this user</a>
+          [%- otheruser.login FILTER url_quote %]">Impersonate this user</a>
         [% END %]
       [% END %]
     [% ELSE %]

Modified: trunk/template/en/default/attachment/CVS/Entries
==============================================================================
--- trunk/template/en/default/attachment/CVS/Entries	(original)
+++ trunk/template/en/default/attachment/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -9,7 +9,7 @@
 /diff-footer.html.tmpl/1.2/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /diff-header.html.tmpl/1.15/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /list.html.tmpl/1.37/Sun Apr  8 13:11:08 2007//TBUGZILLA-3_0-BRANCH
-/show-multiple.html.tmpl/1.22/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /updated.html.tmpl/1.12/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
-/edit.html.tmpl/1.41.2.3/Tue Nov  6 20:18:15 2007//TBUGZILLA-3_0-BRANCH
+/edit.html.tmpl/1.41.2.4/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
+/show-multiple.html.tmpl/1.22.2.1/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
 D

Modified: trunk/template/en/default/attachment/edit.html.tmpl
==============================================================================
--- trunk/template/en/default/attachment/edit.html.tmpl	(original)
+++ trunk/template/en/default/attachment/edit.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -36,13 +36,6 @@
   title = title
   header = header
   subheader = subheader
-  style = "
-    table.attachment_info th { text-align: right; vertical-align: top; }
-    table.attachment_info td { text-align: left; vertical-align: top; }
-    #noview { text-align: left; vertical-align: middle; }
-
-    table#flags th, table#flags td { font-size: small; vertical-align: baseline; text-align: left; }
-  "
 %]
 
 <script type="text/javascript">
@@ -254,6 +247,7 @@
             <label for="isprivate">private</label><br>
           [% END %]
           <br>
+        </small>
 
         [% IF flag_types.size > 0 %]
           [% PROCESS "flag/list.html.tmpl" bug_id = attachment.bug_id
@@ -261,8 +255,8 @@
         [% END %]
 
         <div id="smallCommentFrame">
-          <b><label for="comment">Comment</label> (on the
-          [%+ terms.bug %]):</b><br>
+          <b><small><label for="comment">Comment</label> (on the
+          [%+ terms.bug %]):</small></b><br>
             [% INCLUDE global/textarea.html.tmpl
               id      = 'comment'
               name    = 'comment'
@@ -283,7 +277,6 @@
               && attachment.datasize > 0 %]
           | <a href="attachment.cgi?id=[% attachment.id %]&amp;action=delete">Delete</a>
         [% END %]
-        </small>
       </td>
 
       [% IF !attachment.datasize %]
@@ -306,15 +299,15 @@
             <!--
             if (typeof document.getElementById == "function") {
 [% IF patchviewerinstalled %]
-              document.write('<iframe id="viewDiffFrame" style="height: 400px; width: 100%; display: none;"></iframe>');
+              document.write('<iframe id="viewDiffFrame" style="height: 400px; width: 100%; display: none;"><\/iframe>');
 [% END %]
-              document.write('<button type="button" id="editButton" onclick="editAsComment();">Edit Attachment As Comment</button>');
-              document.write('<button type="button" id="undoEditButton" onclick="undoEditAsComment();" style="display: none;">Undo Edit As Comment</button>');
-              document.write('<button type="button" id="redoEditButton" onclick="redoEditAsComment();" style="display: none;">Redo Edit As Comment</button>');
+              document.write('<button type="button" id="editButton" onclick="editAsComment();">Edit Attachment As Comment<\/button>');
+              document.write('<button type="button" id="undoEditButton" onclick="undoEditAsComment();" style="display: none;">Undo Edit As Comment<\/button>');
+              document.write('<button type="button" id="redoEditButton" onclick="redoEditAsComment();" style="display: none;">Redo Edit As Comment<\/button>');
 [% IF patchviewerinstalled %]
-              document.write('<button type="button" id="viewDiffButton" onclick="viewDiff();">View Attachment As Diff</button>');
+              document.write('<button type="button" id="viewDiffButton" onclick="viewDiff();">View Attachment As Diff<\/button>');
 [% END %]
-              document.write('<button type="button" id="viewRawButton" onclick="viewRaw();" style="display: none;">View Attachment As Raw</button>');
+              document.write('<button type="button" id="viewRawButton" onclick="viewRaw();" style="display: none;">View Attachment As Raw<\/button>');
             }
             //-->
           </script>

Modified: trunk/template/en/default/attachment/show-multiple.html.tmpl
==============================================================================
--- trunk/template/en/default/attachment/show-multiple.html.tmpl	(original)
+++ trunk/template/en/default/attachment/show-multiple.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -32,10 +32,6 @@
   title = title
   header = header
   subheader = filtered_summary
-  style = "
-    table.attachment_info th { text-align: right; vertical-align: top; }
-    table.attachment_info td { text-align: left; vertical-align: top; }
-  "
 %]
 
 <br>

Modified: trunk/template/en/default/bug/CVS/Entries
==============================================================================
--- trunk/template/en/default/bug/CVS/Entries	(original)
+++ trunk/template/en/default/bug/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -3,9 +3,7 @@
 D/process////
 D/votes////
 /choose.html.tmpl/1.7/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
-/comments.html.tmpl/1.28/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /dependency-graph.html.tmpl/1.12/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
-/field.html.tmpl/1.8/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /navigate.html.tmpl/1.8/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /show-multiple.html.tmpl/1.34/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /show.html.tmpl/1.17/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
@@ -15,3 +13,5 @@
 /edit.html.tmpl/1.97.2.2/Sat Aug 11 20:17:24 2007//TBUGZILLA-3_0-BRANCH
 /dependency-tree.html.tmpl/1.25.2.1/Tue Nov  6 20:18:15 2007//TBUGZILLA-3_0-BRANCH
 /summarize-time.html.tmpl/1.8.2.1/Tue Nov  6 20:18:15 2007//TBUGZILLA-3_0-BRANCH
+/comments.html.tmpl/1.28.2.1/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
+/field.html.tmpl/1.8.2.1/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH

Modified: trunk/template/en/default/bug/activity/CVS/Entries
==============================================================================
--- trunk/template/en/default/bug/activity/CVS/Entries	(original)
+++ trunk/template/en/default/bug/activity/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -1,3 +1,3 @@
 /show.html.tmpl/1.8/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
-/table.html.tmpl/1.13/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
+/table.html.tmpl/1.13.2.1/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
 D

Modified: trunk/template/en/default/bug/activity/table.html.tmpl
==============================================================================
--- trunk/template/en/default/bug/activity/table.html.tmpl	(original)
+++ trunk/template/en/default/bug/activity/table.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -74,7 +74,7 @@
                 <a href="attachment.cgi?id=[% change.attachid %]">
                 Attachment #[% change.attachid %]</a>
               [% END %]
-              [% change.field %]
+              [%+ change.field %]
             </td>
             <td>
               [% IF change.removed.defined %]

Modified: trunk/template/en/default/bug/comments.html.tmpl
==============================================================================
--- trunk/template/en/default/bug/comments.html.tmpl	(original)
+++ trunk/template/en/default/bug/comments.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -152,7 +152,8 @@
 [% ELSE %]
     [% wrapped_comment = comment.body FILTER wrap_comment %]
 [% END %]
-<pre[% ' id="comment_text_' _ count _ '"' IF mode == "edit" %]>
+<pre class="bz_comment_text" 
+     [% ' id="comment_text_' _ count _ '"' IF mode == "edit" %]>
   [%- wrapped_comment FILTER quoteUrls(bug.bug_id) -%]
 </pre>
     </div>

Modified: trunk/template/en/default/bug/create/CVS/Entries
==============================================================================
--- trunk/template/en/default/bug/create/CVS/Entries	(original)
+++ trunk/template/en/default/bug/create/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -1,9 +1,9 @@
 /comment-guided.txt.tmpl/1.5/Sun Apr  8 13:11:08 2007//TBUGZILLA-3_0-BRANCH
 /comment.txt.tmpl/1.4/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /confirm-create-dupe.html.tmpl/1.3/Sun Jan 21 15:43:20 2007//TBUGZILLA-3_0-BRANCH
-/create.html.tmpl/1.75/Sun Apr  8 13:11:08 2007//TBUGZILLA-3_0-BRANCH
 /created.html.tmpl/1.9/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /make-template.html.tmpl/1.9/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /user-message.html.tmpl/1.4/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /create-guided.html.tmpl/1.36.2.2/Sun Sep  2 09:52:05 2007//TBUGZILLA-3_0-BRANCH
+/create.html.tmpl/1.75.2.1/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
 D

Modified: trunk/template/en/default/bug/create/create.html.tmpl
==============================================================================
--- trunk/template/en/default/bug/create/create.html.tmpl	(original)
+++ trunk/template/en/default/bug/create/create.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -277,10 +277,21 @@
     %]
     <td rowspan="[% num_rows FILTER html %]" valign="top">
       [% IF product.flag_types.bug.size > 0 %]
-        [% PROCESS "flag/list.html.tmpl" flag_types = product.flag_types.bug
-                                         any_flags_requesteeble = 1
-                                         flag_table_id = "bug_flags"
-        %]
+        [% display_flag_headers = 0 %]
+        [% any_flags_requesteeble = 0 %]
+
+        [% FOREACH flag_type = product.flag_types.bug %]
+          [% NEXT UNLESS flag_type.is_active %]
+          [% display_flag_headers = 1 %]
+          [% SET any_flags_requesteeble = 1 IF flag_type.is_requestable && flag_type.is_requesteeble %]
+        [% END %]
+
+        [% IF display_flag_headers %]
+          [% PROCESS "flag/list.html.tmpl" flag_types = product.flag_types.bug
+                                           any_flags_requesteeble = any_flags_requesteeble
+                                           flag_table_id = "bug_flags"
+          %]
+        [% END %]
       [% END %]
     </td>
   </tr>

Modified: trunk/template/en/default/bug/field.html.tmpl
==============================================================================
--- trunk/template/en/default/bug/field.html.tmpl	(original)
+++ trunk/template/en/default/bug/field.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -42,7 +42,9 @@
 [% IF editable %]
   [% SWITCH field.type %]
     [% CASE constants.FIELD_TYPE_FREETEXT %]
-        <input name="[% field.name FILTER html %]" value="[% value FILTER html %]" size="60">
+        <input id="[% field.name FILTER html %]" name="[% field.name FILTER html %]"
+               value="[% value FILTER html %]" size="60"
+               maxlength="[% constants.MAX_FREETEXT_LENGTH FILTER none %]">
     [% CASE constants.FIELD_TYPE_SINGLE_SELECT %]
         <select id="[% field.name FILTER html %]" name="[% field.name FILTER html %]">
           [% IF allow_dont_change %]

Modified: trunk/template/en/default/bug/process/CVS/Entries
==============================================================================
--- trunk/template/en/default/bug/process/CVS/Entries	(original)
+++ trunk/template/en/default/bug/process/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -1,7 +1,7 @@
 /bugmail.html.tmpl/1.7/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /confirm-duplicate.html.tmpl/1.11/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /header.html.tmpl/1.5/Sun Apr  8 13:11:08 2007//TBUGZILLA-3_0-BRANCH
-/midair.html.tmpl/1.19/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /results.html.tmpl/1.11/Mon Jan  1 00:11:05 2007//TBUGZILLA-3_0-BRANCH
 /verify-new-product.html.tmpl/1.20.2.2/Sat Aug 11 20:17:24 2007//TBUGZILLA-3_0-BRANCH
+/midair.html.tmpl/1.19.2.1/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
 D

Modified: trunk/template/en/default/bug/process/midair.html.tmpl
==============================================================================
--- trunk/template/en/default/bug/process/midair.html.tmpl	(original)
+++ trunk/template/en/default/bug/process/midair.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -67,7 +67,9 @@
 [% IF cgi.param("comment") %]
 <p>
   Your comment was:<br>
-  <blockquote><pre>[% cgi.param("comment") FILTER wrap_comment FILTER html %]</pre></blockquote>
+  <blockquote><pre class="bz_comment_text">
+    [% cgi.param("comment") FILTER wrap_comment FILTER html %]
+  </pre></blockquote>
 </p>
 [% END %]
 

Modified: trunk/template/en/default/email/CVS/Entries
==============================================================================
--- trunk/template/en/default/email/CVS/Entries	(original)
+++ trunk/template/en/default/email/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -1,5 +1,5 @@
-/votes-removed.txt.tmpl/1.2/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /whine.txt.tmpl/1.3/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /newchangedmail.txt.tmpl/1.6.2.1/Sat May 12 19:37:52 2007//TBUGZILLA-3_0-BRANCH
 /sudo.txt.tmpl/1.2.2.1/Sat Aug 11 20:17:24 2007//TBUGZILLA-3_0-BRANCH
+/votes-removed.txt.tmpl/1.2.2.1/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
 D

Modified: trunk/template/en/default/email/votes-removed.txt.tmpl
==============================================================================
--- trunk/template/en/default/email/votes-removed.txt.tmpl	(original)
+++ trunk/template/en/default/email/votes-removed.txt.tmpl	Fri Apr 11 17:31:30 2008
@@ -28,11 +28,28 @@
 
 Some or all of your votes have been removed from [% terms.bug %] [%+ bugid %].
 
-[% votesoldtext %]
+You had [% votesold FILTER html %] [%+ IF votesold == 1 %]vote[% ELSE %]votes[% END
+%] on this [% terms.bug %], but [% votesremoved FILTER html %] have been removed.
 
-[% votesnewtext %]
+[% IF votesnew %]
+You still have [% votesnew FILTER html %] [%+ IF votesnew == 1 %]vote[% ELSE %]votes[% END %] on this [% terms.bug %].
+[% ELSE %]
+You have no more votes remaining on this [% terms.bug %].
+[% END %]
+
+Reason:
+[% IF reason == "votes_bug_moved" %]
+  This [% terms.bug %] has been moved to a different product.
+
+[% ELSIF reason == "votes_too_many_per_bug" %]
+  The rules for voting on this product has changed;
+  you had too many votes for a single [% terms.bug %].
+
+[% ELSIF reason == "votes_too_many_per_user" %]
+  The rules for voting on this product has changed; you had
+  too many total votes, so all votes have been removed.
+[% END %]
 
-Reason: [% reason %]
 
 
 [% Param("urlbase") %]show_bug.cgi?id=[% bugid %]

Modified: trunk/template/en/default/flag/CVS/Entries
==============================================================================
--- trunk/template/en/default/flag/CVS/Entries	(original)
+++ trunk/template/en/default/flag/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -1,2 +1,2 @@
-/list.html.tmpl/1.27.2.1/Sat Aug 11 20:17:24 2007//TBUGZILLA-3_0-BRANCH
+/list.html.tmpl/1.27.2.2/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
 D

Modified: trunk/template/en/default/flag/list.html.tmpl
==============================================================================
--- trunk/template/en/default/flag/list.html.tmpl	(original)
+++ trunk/template/en/default/flag/list.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -128,7 +128,7 @@
         </td>
         [% IF any_flags_requesteeble %]
           <td>
-            [% IF type.is_active && type.is_requesteeble %]
+            [% IF (type.is_active && type.is_requestable && type.is_requesteeble) || flag.requestee %]
               <span style="white-space: nowrap;">
                 (<input type="text" size="30" maxlength="255"
                         id="requestee-[% flag.id %]" 
@@ -171,7 +171,7 @@
         </td>
         [% IF any_flags_requesteeble %]
           <td>
-            [% IF type.is_requesteeble %]
+            [% IF type.is_requestable && type.is_requesteeble %]
               <span style="white-space: nowrap;">
                 (<input type="text" size="30" maxlength="255"
                         id="requestee_type-[% type.id %]" 
@@ -215,7 +215,7 @@
       </td>
       [% IF any_flags_requesteeble %]
         <td>
-          [% IF type.is_requesteeble %]
+          [% IF type.is_requestable && type.is_requesteeble %]
               <span style="white-space: nowrap;">
                 (<input type="text" size="30" maxlength="255"
                         id="requestee_type-[% type.id %]" 

Modified: trunk/template/en/default/global/CVS/Entries
==============================================================================
--- trunk/template/en/default/global/CVS/Entries	(original)
+++ trunk/template/en/default/global/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -18,12 +18,12 @@
 /site-navigation.html.tmpl/1.22/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /tabs.html.tmpl/1.3/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /userselect.html.tmpl/1.5/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
-/variables.none.tmpl/1.4/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /textarea.html.tmpl/1.1.2.1/Sat May 12 19:37:52 2007//TBUGZILLA-3_0-BRANCH
 /code-error.html.tmpl/1.92.2.4/Sat Aug 11 20:17:24 2007//TBUGZILLA-3_0-BRANCH
-/header.html.tmpl/1.49.2.1/Sat Aug 11 20:17:24 2007//TBUGZILLA-3_0-BRANCH
 /messages.html.tmpl/1.49.2.5/Sat Aug 11 20:17:24 2007//TBUGZILLA-3_0-BRANCH
 /setting-descs.none.tmpl/1.11.2.1/Sat Aug 11 20:17:24 2007//TBUGZILLA-3_0-BRANCH
 /useful-links.html.tmpl/1.56.2.2/Sat Aug 11 20:17:24 2007//TBUGZILLA-3_0-BRANCH
-/user-error.html.tmpl/1.204.2.7/Sun Sep  2 09:52:05 2007//TBUGZILLA-3_0-BRANCH
+/header.html.tmpl/1.49.2.2/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
+/user-error.html.tmpl/1.204.2.14/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
+/variables.none.tmpl/1.4.2.1/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
 D

Modified: trunk/template/en/default/global/header.html.tmpl
==============================================================================
--- trunk/template/en/default/global/header.html.tmpl	(original)
+++ trunk/template/en/default/global/header.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -213,6 +213,8 @@
     [%# Required for the 'Autodiscovery' feature in Firefox 2 and IE 7. %]
     <link rel="search" type="application/opensearchdescription+xml"
                        title="[% terms.Bugzilla %]" href="./search_plugin.cgi">
+                       
+    [% Hook.process("additional_header") %]                   
   </head>
 
 [%# Migration note: contents of the old Param 'bodyhtml' go in the body tag,

Modified: trunk/template/en/default/global/user-error.html.tmpl
==============================================================================
--- trunk/template/en/default/global/user-error.html.tmpl	(original)
+++ trunk/template/en/default/global/user-error.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -250,6 +250,11 @@
     [% title = "Classification Not Enabled" %]
     Sorry, classification is not enabled.
 
+  [% ELSIF error == "bug_status_not_allowed" %]
+    [% title = "$terms.Bug Status Not Allowed" %]
+    You cannot mark open [% terms.bugs %] as [% status_descs.$status FILTER html %].
+    You have to mark them as [% status_descs.RESOLVED FILTER html %] first.
+
   [% ELSIF error == "classification_not_specified" %]
     [% title = "You Must Supply A Classification Name" %]
     You must enter a classification name.
@@ -571,6 +576,13 @@
     The sort key must be an integer between 0 and 32767 inclusive.
     It cannot be <em>[% sortkey FILTER html %]</em>.
 
+  [% ELSIF error == "freetext_too_long" %]
+    [% title = "Text Too Long" %]
+    The text you entered is too long ([% text.length FILTER html %] characters,
+    above the maximum length allowed of [% constants.MAX_FREETEXT_LENGTH FILTER none %]
+    characters):
+    <p><em>[% text FILTER html %]</em></p>
+
   [% ELSIF error == "group_cannot_delete" %]
     [% title = "Cannot Delete Group" %]
     The <em>[% name FILTER html %]</em> group cannot be deleted because
@@ -1201,7 +1213,7 @@
     create the milestone '[% defaultmilestone FILTER html %]'</a> before
     it can be made the default milestone for product '[% product FILTER html %]'.
 
-  [% ELSIF error == "product_access_denied" %]
+  [% ELSIF error == "product_admin_denied" %]
     [% title = "Product Access Denied" %]
     You are not allowed to edit properties of product '[% product FILTER html %]'.
 
@@ -1299,6 +1311,10 @@
     [% title = "Summary Needed" %]
     You must enter a summary for this [% terms.bug %].
 
+  [% ELSIF error == "resolution_deletion_not_allowed" %]
+    [% title = "Resolution Change Not Allowed" %]
+    You cannot clear the resolution of non-open [% terms.bugs %].
+
   [% ELSIF error == "resolution_not_allowed" %]
     [% title = "Resolution Not Allowed" %]
     You cannot set a resolution for open [% terms.bugs %].

Modified: trunk/template/en/default/global/variables.none.tmpl
==============================================================================
--- trunk/template/en/default/global/variables.none.tmpl	(original)
+++ trunk/template/en/default/global/variables.none.tmpl	Fri Apr 11 17:31:30 2008
@@ -28,19 +28,6 @@
   # Remember to PROCESS rather than INCLUDE this template. 
   #%]
 
-[%# Note on changing terms:
-  # Changing this will not affect "linkification" of your new terms.
-  # This means if you change "bug" to "problem", then if you have
-  # "problem 3" in a comment, it won't become a clickable URL.
-  # To have that feature, you must edit the quoteUrls function in
-  # Bugzilla/Template.pm.
-  # Change the line:
-  # my $bug_re = qr/bug\s*\#?\s*(\d+)/i;
-  # to something like:
-  # my $bug_re = qr/(?:bug|problem)\s*\#?\s*(\d+)/i;
-  # (here "problem" was used instead of bug - substitute as needed!).
-  #%]
-
 [% terms = {
   "bug" => "bug",
   "Bug" => "Bug",

Modified: trunk/template/en/default/pages/CVS/Entries
==============================================================================
--- trunk/template/en/default/pages/CVS/Entries	(original)
+++ trunk/template/en/default/pages/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -1,10 +1,10 @@
-/fields.html.tmpl/1.9/Sun Jan 21 15:43:20 2007//TBUGZILLA-3_0-BRANCH
-/linked.html.tmpl/1.8/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /linkify.html.tmpl/1.8/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /quicksearch.html.tmpl/1.2/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
-/quicksearchhack.html.tmpl/1.3/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /sudo.html.tmpl/1.1/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /voting.html.tmpl/1.3/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /bug-writing.html.tmpl/1.6.2.2/Sat Aug 11 20:17:24 2007//TBUGZILLA-3_0-BRANCH
-/release-notes.html.tmpl/1.1.2.8/Tue Nov  6 20:18:15 2007//TBUGZILLA-3_0-BRANCH
+/fields.html.tmpl/1.9.2.2/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
+/linked.html.tmpl/1.8.8.1/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
+/quicksearchhack.html.tmpl/1.3.2.1/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
+/release-notes.html.tmpl/1.1.2.10/Fri Apr 11 16:25:53 2008//TBUGZILLA-3_0-BRANCH
 D

Modified: trunk/template/en/default/pages/fields.html.tmpl
==============================================================================
--- trunk/template/en/default/pages/fields.html.tmpl	(original)
+++ trunk/template/en/default/pages/fields.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -90,7 +90,7 @@
         </dt>
         <dd>
           This [% terms.bug %] was once resolved, but the resolution was 
-          deemed incorrect. For example, a <b>[% status_descs.WORKSFORME FILTER html %]</b> [% terms.bug %] is
+          deemed incorrect. For example, a <b>[% get_resolution("WORKSFORME") FILTER html %]</b> [% terms.bug %] is
           <b>[% status_descs.REOPENED FILTER html %]</b> when more information shows up and
           the [% terms.bug %] is now reproducible. From here [% terms.bugs %] are
           either marked <b>[% status_descs.ASSIGNED FILTER html %]</b> or <b>[% status_descs.RESOLVED FILTER html %]</b>.
@@ -227,6 +227,13 @@
   </tr>
 
   <tr>
+    <th>Normal</th>
+
+    <td>regular issue, some loss of functionality under specific circumstances</td>
+  </tr>
+
+
+  <tr>
     <th>Minor</th>
 
     <td>minor loss of function, or other problem where easy

Modified: trunk/template/en/default/pages/linked.html.tmpl
==============================================================================
--- trunk/template/en/default/pages/linked.html.tmpl	(original)
+++ trunk/template/en/default/pages/linked.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -31,7 +31,7 @@
 <hr>
 
 <p>
-<pre>
+<pre class="bz_comment_text">
 [%- cgi.param("text") FILTER wrap_comment FILTER quoteUrls FILTER html -%]
 </pre>
 </p>
@@ -46,7 +46,7 @@
 <hr>
 
 <p>
-<pre>
+<pre class="bz_comment_text">
 [%- cgi.param("text") FILTER wrap_comment FILTER quoteUrls -%]
 </pre>
 </p>

Modified: trunk/template/en/default/pages/quicksearchhack.html.tmpl
==============================================================================
--- trunk/template/en/default/pages/quicksearchhack.html.tmpl	(original)
+++ trunk/template/en/default/pages/quicksearchhack.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -264,7 +264,17 @@
   <td><tt>attachmimetype</tt></td>
   <td>Attachment mime-type <i>(&ldquo;attachments.mimetype&rdquo;)</i></td>
 </tr>
-
+<tr>
+  <td>&nbsp;</td>
+  <td>&nbsp;</td>
+  <td><tt>votes</tt></td>
+  <td>&nbsp;</td>
+  <td>
+    Number of votes<br>
+    (votes:<i>N</i> and votes&gt;=<i>N</i> mean "at least N votes",
+    votes&gt;<i>N</i> means "more than N votes")
+  </td>
+</tr>
 </table>
 
 <p>
@@ -301,19 +311,6 @@
   <td><b>:</b><i>area</i></td>
   <td><b>product,component:</b><i>area</i></td>
 </tr>
-<!--
-<tr>
-  <td><tt>:browser</tt></td>
-  <td><i>[% terms.bugs %] in the Browser product</i></td>
-</tr>
- <td><tt>:mail</tt></td>
-  <td><i>[% terms.bugs %] in the MailNews product</td>
-</tr>
-<tr>
-  <td><tt>:xbl</tt></td>
-  <td><i>[% terms.bugs %] in the XBL component</i></td>
-</tr>
-  -->
 <tr>
   <td><i>sev</i></td>
   <td><b>severity:</b><i>sev</i></td>
@@ -342,30 +339,10 @@
   <td><b>@</b><i>assignee</i></td>
   <td><b>assignedto:</b><i>assignee</i></td>
 </tr>
-<!--
-<tr>
-  <td><tt>@nobody</tt></td>
-  <td><i>assigneeless [% terms.bugs %]</i></td>
-</tr>
-<tr>
-  <td><tt>@mozilla.org</tt></td>
-  <td><i>[% terms.bugs %] assigned to mozilla.org members</i></td>
-</tr>
-  -->
 <tr>
   <td><b>!</b><i>keyword</i></td>
   <td><b>keywords:</b><i>keyword</i></td>
 </tr>
-<!--
-<tr>
-  <td><tt>!crash</tt></td>
-  <td><i>crasher [% terms.bugs %]</i></td>
-</tr>
-<tr>
-  <td><tt>!helpwanted</tt></td>
-  <td><i>[% terms.bugs %] waiting for your help</i></td>
-</tr>
-  -->
 </table>
 
 <p>

Modified: trunk/template/en/default/pages/release-notes.html.tmpl
==============================================================================
--- trunk/template/en/default/pages/release-notes.html.tmpl	(original)
+++ trunk/template/en/default/pages/release-notes.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -20,7 +20,7 @@
 
 [% PROCESS global/variables.none.tmpl %]
 [% INCLUDE global/header.html.tmpl 
-  title = "$terms.Bugzilla 3.0.2 Release Notes" 
+  title = "$terms.Bugzilla 3.0.3 Release Notes" 
   style_urls = ['skins/standard/release-notes.css'] 
 %]
 
@@ -61,6 +61,42 @@
   <em>everything</em> that's changed in each version, you should use our
   <a href="http://www.bugzilla.org/status/changes.html";>Change Log Page</a>.</p>
 
+<h3>3.0.3</h3>
+
+<ul>
+  <li>mod_perl no longer compiles [% terms.Bugzilla %]'s code for each Apache
+    process individually. It now compiles code only once and shares it among
+    each Apache process. This greatly improves performance and highly 
+    decreases the memory footprint.
+   (<a href="https://bugzilla.mozilla.org/show_bug.cgi?id=398241";>[% terms.Bug %] 398241</a>)</li>
+
+  <li>You can now search for '---' (without quotes) in versions and milestones.
+    (<a href="https://bugzilla.mozilla.org/show_bug.cgi?id=362436";>[% terms.Bug %] 362436</a>)</li>
+
+  <li>[% terms.Bugzilla %] should no longer break lines unnecessarily in 
+    email subjects. This was causing trouble with some email clients.
+    (<a href="https://bugzilla.mozilla.org/show_bug.cgi?id=374424";>[% terms.Bug %] 374424</a>)</li>
+
+  <li>If you had selected "I'm added to or removed from this capacity" option
+    for the "CC" role in your email preferences, you wouldn't get mail when
+    more than one person was added to the CC list at once.
+    (<a href="https://bugzilla.mozilla.org/show_bug.cgi?id=394796";>[% terms.Bug %] 394796</a>)</li>
+
+  <li>Deleting a user account no longer deletes whines from another user who
+    has the deleted account as addressee. The schedule is simply removed, 
+    but the whine itself is left intact.
+    (<a href="https://bugzilla.mozilla.org/show_bug.cgi?id=395924";>[% terms.Bug %] 395924</a>)</li>
+
+  <li><kbd>contrib/merge-users.pl</kbd> now correctly merges all required
+    fields when merging two user accounts.
+    (<a href="https://bugzilla.mozilla.org/show_bug.cgi?id=400160";>[% terms.Bug %] 400160</a>)</li>
+
+  <li>[% terms.Bugzilla %] no longer requires Apache::DBI to run under 
+    mod_perl. It caused troubles such as lost connections with the DB and
+    didn't give any important performance gain.
+    (<a href="https://bugzilla.mozilla.org/show_bug.cgi?id=408766";>[% terms.Bug %] 408766</a>)</li>
+</ul>
+
 <h3>3.0.2</h3>
 
 <ul>
@@ -576,6 +612,10 @@
 
 <h2><a name="v30_security"></a>Security Updates in This Release</h2>
 
+<h3>3.0.3</h3>
+
+<p>No security fixes in this release.</p>
+
 <h3>3.0.2</h3>
 
 <p>[% terms.Bugzilla %] 3.0.1 had an important security fix that is

Modified: trunk/template/en/default/search/CVS/Entries
==============================================================================
--- trunk/template/en/default/search/CVS/Entries	(original)
+++ trunk/template/en/default/search/CVS/Entries	Fri Apr 11 17:31:30 2008
@@ -1,5 +1,4 @@
 /boolean-charts.html.tmpl/1.15/Mon Jan  1 02:45:18 2007//TBUGZILLA-3_0-BRANCH
-/form.html.tmpl/1.47/Result of merge//TBUGZILLA-3_0-BRANCH
 /search-advanced.html.tmpl/1.29/Sun Apr  8 13:11:08 2007//TBUGZILLA-3_0-BRANCH
 /search-create-series.html.tmpl/1.12/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
 /search-report-select.html.tmpl/1.6/Mon Jan  1 00:11:04 2007//TBUGZILLA-3_0-BRANCH
@@ -10,4 +9,5 @@
 /search-help.html.tmpl/1.8.2.1/Sat Aug 11 20:17:24 2007//TBUGZILLA-3_0-BRANCH
 /search-report-graph.html.tmpl/1.9.2.1/Sat Aug 11 20:17:24 2007//TBUGZILLA-3_0-BRANCH
 /search-specific.html.tmpl/1.20.2.3/Sat Aug 11 20:17:24 2007//TBUGZILLA-3_0-BRANCH
+/form.html.tmpl/1.47.2.1/Result of merge//TBUGZILLA-3_0-BRANCH
 D

Modified: trunk/template/en/default/search/form.html.tmpl
==============================================================================
--- trunk/template/en/default/search/form.html.tmpl	(original)
+++ trunk/template/en/default/search/form.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -325,10 +325,10 @@
         <label for="deadlinefrom" accesskey="l">Dead<u>l</u>ine</label>:
       </th>
       <td>
-        from&nbsp;
-        <input name="deadlinefrom" id="deadlinefrom" size="10" maxlength="10">&nbsp;
-        to&nbsp;
-        <input name="deadlineto" size="10" maxlength="10">
+        from <input name="deadlinefrom" id="deadlinefrom" size="10" maxlength="10"
+                    value="[% default.deadlinefrom.0 FILTER html %]">
+        to <input name="deadlineto" size="10" maxlength="10"
+                  value="[% default.deadlineto.0 FILTER html %]">
       </td>
       <td>
         <small>(YYYY-MM-DD)</small>

Modified: trunk/template/en/default/welcome-admin.html.tmpl
==============================================================================
--- trunk/template/en/default/welcome-admin.html.tmpl	(original)
+++ trunk/template/en/default/welcome-admin.html.tmpl	Fri Apr 11 17:31:30 2008
@@ -24,7 +24,7 @@
 
 [% PROCESS global/header.html.tmpl
    title = title
-   h3 = "version $constants.BUGZILLA_VERSION"
+   header_addl_info = "version $constants.BUGZILLA_VERSION"
    style_urls = [ 'skins/standard/index.css' ]
 %]
 

Modified: trunk/token.cgi
==============================================================================
--- trunk/token.cgi	(original)
+++ trunk/token.cgi	Fri Apr 11 17:31:30 2008
@@ -101,11 +101,10 @@
 # If the user is requesting a password change, make sure they submitted
 # their login name and it exists in the database, and that the DB module is in
 # the list of allowed verification methods.
-my $login_name;
+my $user_account;
 if ( $::action eq 'reqpw' ) {
-    $login_name = $cgi->param('loginname');
-    defined $login_name
-      || ThrowUserError("login_needed_for_password_change");
+    my $login_name = $cgi->param('loginname')
+                       || ThrowUserError("login_needed_for_password_change");
 
     # check verification methods
     unless (Bugzilla->user->authorizer->can_change_password) {
@@ -115,10 +114,8 @@
     validate_email_syntax($login_name)
         || ThrowUserError('illegal_email_address', {addr => $login_name});
 
-    my ($user_id) = $dbh->selectrow_array('SELECT userid FROM profiles WHERE ' .
-                                          $dbh->sql_istrcmp('login_name', '?'),
-                                          undef, $login_name);
-    $user_id || ThrowUserError("account_inexistent");
+    $user_account = new Bugzilla::User({name => $login_name});
+    $user_account || ThrowUserError("account_inexistent");
 }
 
 # If the user is changing their password, make sure they submitted a new
@@ -142,7 +139,7 @@
 # that variable and runs the appropriate code.
 
 if ($::action eq 'reqpw') { 
-    requestChangePassword($login_name);
+    requestChangePassword($user_account);
 } elsif ($::action eq 'cfmpw') { 
     confirmChangePassword(); 
 } elsif ($::action eq 'cxlpw') { 
@@ -175,8 +172,8 @@
 ################################################################################
 
 sub requestChangePassword {
-    my ($login_name) = @_;
-    Bugzilla::Token::IssuePasswordToken($login_name);
+    my ($user) = @_;
+    Bugzilla::Token::IssuePasswordToken($user);
 
     $vars->{'message'} = "password_change_request";
 

Modified: trunk/userprefs.cgi
==============================================================================
--- trunk/userprefs.cgi	(original)
+++ trunk/userprefs.cgi	Fri Apr 11 17:31:30 2008
@@ -138,7 +138,7 @@
             is_available_username($new_login_name)
               || ThrowUserError("account_exists", {email => $new_login_name});
 
-            Bugzilla::Token::IssueEmailChangeToken($user->id, $old_login_name,
+            Bugzilla::Token::IssueEmailChangeToken($user, $old_login_name,
                                                    $new_login_name);
 
             $vars->{'email_changes_saved'} = 1;

Modified: trunk/whine.pl
==============================================================================
--- trunk/whine.pl	(original)
+++ trunk/whine.pl	Fri Apr 11 17:31:30 2008
@@ -358,10 +358,11 @@
 #
 sub mail {
     my $args = shift;
+    my $addressee = $args->{recipient};
+    # Don't send mail to someone whose bugmail notification is disabled.
+    return if $addressee->email_disabled;
 
-    # Don't send mail to someone on the nomail list.
-    return if $args->{recipient}->email_disabled;
-
+    my $template = Bugzilla->template_inner($addressee->settings->{'lang'}->{'value'});
     my $msg = ''; # it's a temporary variable to hold the template output
     $args->{'alternatives'} ||= [];
 
@@ -392,6 +393,7 @@
     $template->process("whine/multipart-mime.txt.tmpl", $args, \$msg)
         or die($template->error());
 
+    Bugzilla->template_inner("");
     MessageToMTA($msg);
 
     delete $args->{'boundary'};

Modified: trunk/whineatnews.pl
==============================================================================
--- trunk/whineatnews.pl	(original)
+++ trunk/whineatnews.pl	Fri Apr 11 17:31:30 2008
@@ -85,9 +85,11 @@
     $vars->{'bugs'} = \ bugs;
 
     my $msg;
-    my $template = Bugzilla->template;
-    $template->process("email/whine.txt.tmpl", $vars, \$msg);
+    my $template = Bugzilla->template_inner($user->settings->{'lang'}->{'value'});
+    $template->process("email/whine.txt.tmpl", $vars, \$msg)
+      or die($template->error());
 
+    Bugzilla->template_inner("");
     MessageToMTA($msg);
 
     print "$email      " . join(" ", @{$bugs{$email}}) . "\n";



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]