From 44b48df3901d829e1423749136d142964ccb4a3e Mon Sep 17 00:00:00 2001 From: "gerv%gerv.net" <> Date: Fri, 4 Jul 2003 04:31:13 +0000 Subject: Bug 13540 - allow key terms, like "Bugzilla" and "bug", to be altered without changing all the templates. Patch by jwilmoth@starbucks.com; r=gerv, a=justdave. --- template/en/default/global/banner.html.tmpl | 4 +- .../en/default/global/choose-product.html.tmpl | 10 +- template/en/default/global/code-error.html.tmpl | 56 ++--- template/en/default/global/field-descs.none.tmpl | 10 +- template/en/default/global/footer.html.tmpl | 9 +- template/en/default/global/header.html.tmpl | 20 +- template/en/default/global/hidden-fields.html.tmpl | 6 +- template/en/default/global/message.html.tmpl | 6 +- template/en/default/global/messages.html.tmpl | 22 +- .../en/default/global/site-navigation.html.tmpl | 10 +- template/en/default/global/useful-links.html.tmpl | 18 +- template/en/default/global/user-error.html.tmpl | 254 +++++++++++---------- template/en/default/global/variables.none.tmpl | 44 ++++ 13 files changed, 267 insertions(+), 202 deletions(-) create mode 100644 template/en/default/global/variables.none.tmpl (limited to 'template/en/default/global') diff --git a/template/en/default/global/banner.html.tmpl b/template/en/default/global/banner.html.tmpl index b8bf4e06d..f1a8f14ae 100644 --- a/template/en/default/global/banner.html.tmpl +++ b/template/en/default/global/banner.html.tmpl @@ -22,12 +22,14 @@ [%# Migration note: this file corresponds to the old Param 'bannerhtml' %] +[% PROCESS global/variables.none.tmpl %] +
|
[% field %]
and [% type FILTER html %]
together.
-
+
[% ELSIF error == "gd_not_installed" %]
Charts will not work without the GD Perl module being installed.
Run checksetup.pl for installation instructions.
@@ -93,17 +95,17 @@
[% ELSIF error == "illegal_content_type_method" %]
Your form submission got corrupted somehow. The content
method field, which specifies how the content type gets determined,
- should have been either autodetect, list,
- or manual, but was instead
+ should have been either autodetect, list,
+ or manual, but was instead
[% contenttypemethod FILTER html %].
-
+
[% ELSIF error == "illegal_field" %]
A legal [% field FILTER html %] was not set.
-
+
[% ELSIF error == "inactive_group" %]
- Attempted to add bug to an inactive group, identified by the bit
+ Attempted to add [% terms.bug %] to an inactive group, identified by the bit
'[% bit FILTER html %]'.
-
+
[% ELSIF error == "bad_arg" %]
Bad argument [% argument %]
sent to
[% function %]
function.
@@ -139,12 +141,12 @@
[% ELSIF error == "mismatched_bug_ids_on_obsolete" %]
Attachment [% attach_id FILTER html %] ([% description FILTER html %])
- is attached to bug [% attach_bug_id FILTER html %], but you tried to
- flag it as obsolete while creating a new attachment to bug
- [% my_bug_id FILTER html %].
+ is attached to [% terms.bug %] [%+ attach_bug_id FILTER html %],
+ but you tried to flag it as obsolete while creating a new attachment to
+ [% terms.bug %] [%+ my_bug_id FILTER html %].
[% ELSIF error == "no_bug_data" %]
- No data when fetching bug [% bug_id %].
+ No data when fetching [% terms.bug %] [%+ bug_id %].
[% ELSIF error == "flag_nonexistent" %]
There is no flag with ID #[% variables.id %].
@@ -170,7 +172,7 @@
The product [% variables.product FILTER html %] does not exist.
[% ELSIF error == "flag_type_target_type_invalid" %]
- The target type was neither bug nor attachment
+ The target type was neither [% terms.bug %] nor attachment
but rather [% variables.target_type FILTER html %].
[% ELSIF error == "invalid_field_name" %]
@@ -181,7 +183,7 @@
Invalid output type [% type FILTER html %].
[% ELSIF error == "missing_bug_id" %]
- No bug ID was given.
+ No [% terms.bug %] ID was given.
[% ELSIF error == "missing_series_id" %]
Having inserted a series into the database, no series_id was returned for
@@ -200,7 +202,7 @@
The group field [% group FILTER html %] is invalid.
[% ELSIF error == "report_axis_invalid" %]
- [% variables.val FILTER html %] is not a valid value for
+ [% variables.val FILTER html %] is not a valid value for
[%+ IF variables.fld == "x" %]the horizontal axis
[%+ ELSIF variables.fld == "y" %]the vertical axis
[%+ ELSIF variables.fld == "z" %]the multiple tables/images
@@ -214,7 +216,7 @@
[% ELSIF error == "unable_to_retrieve_password" %]
I was unable to retrieve your old password from the database.
-
+
[% ELSIF error == "undefined_field" %]
[% field FILTER html %] was not defined; [% Param('browserbugmessage') %]
@@ -224,7 +226,7 @@
[% ELSE %]
I could not figure out what you wanted to do.
[% END %]
-
+
[% ELSIF error == "unknown_component" %]
[% title = "Unknown Component" %]
There is no component named [% variables.component FILTER html %].
@@ -235,12 +237,12 @@
[% ELSE %]
[%# Give sensible error if error functions are used incorrectly.
- #%]
- You are using Bugzilla's ThrowCodeError() function incorrectly. You
+ #%]
+ You are using [% terms.Bugzilla %]'s ThrowCodeError() function incorrectly. You
passed in the string '[% error %]'. The correct use is to pass
in a tag, and define that tag in the file code-error.html.tmpl.- Bugzilla has suffered an internal error. Please save this page and send - it to [% Param("maintainer") %] with details of what you were doing at + [% terms.Bugzilla %] has suffered an internal error. Please save this page and send + it to [% Param("maintainer") %] with details of what you were doing at the time this message appeared.
[% END %] - - [%+ INCLUDE "global/help-header.html.tmpl" %] + + [%+ INCLUDE "global/help-header.html.tmpl" %] [% IF style %] [% END %] - + [% IF style_urls %] [% FOREACH style_url = style_urls %] [% END %] [% END %] - + - + [%# Migration note: contents of the old Param 'bodyhtml' go in the body tag, # but set the bgcolor and onload attributes in the DEFAULT directive above. #%] @@ -94,9 +94,9 @@ [%# Migration note: the following file corresponds to the old Param # 'bannerhtml' #%] - + [% INCLUDE global/banner.html.tmpl %] - + [% IF h1 || h2 %][% flag_type.name FILTER html %]
on bug [% bug_id -%]
- [% IF attach_id %], attachment [% attach_id %][% END %], but that bug
+ for [% flag_type.name FILTER html %]
on [% terms.bug %] [% bug_id -%]
+ [% IF attach_id %], attachment [% attach_id %][% END %], but that [% terms.bug %]&bnsp;
has been restricted to users in certain groups, and the user you asked
- isn't in all the groups to which the bug has been restricted.
- Please choose someone else to ask, or make the bug accessible to users
+ isn't in all the groups to which the [% terms.bug %] has been restricted.
+ Please choose someone else to ask, or make the [% terms.bug %] accessible to users
on its CC: list and add that user to the list.
-
+
[% ELSIF error == "flag_requestee_unauthorized_attachment" %]
[% title = "Flag Requestee Not Authorized" %]
You asked [% requestee.identity FILTER html %]
- for [% flag_type.name FILTER html %]
on bug [% bug_id %],
- attachment [% attach_id %], but that attachment is restricted to users
+ for [% flag_type.name FILTER html %]
on [% terms.bug %] [% bug_id %],
+ attachment [% attach_id %], but that attachment is restricted to users
in the [% Param("insidergroup") FILTER html %] group, and the user
you asked isn't in that group. Please choose someone else to ask,
or ask an administrator to add the user to the group.
-
+
[% ELSIF error == "flag_type_cc_list_invalid" %]
[% title = "Flag Type CC List Invalid" %]
The CC list [% cc_list FILTER html %] must be less than 200 characters long.
-
+
[% ELSIF error == "flag_type_description_invalid" %]
[% title = "Flag Type Description Invalid" %]
The description must be less than 32K.
-
+
[% ELSIF error == "flag_type_name_invalid" %]
[% title = "Flag Type Name Invalid" %]
The name [% name FILTER html %] must be 1-50 characters long.
@@ -234,7 +237,7 @@
[% ELSIF error == "illegal_attachment_edit_bug" %]
[% title = "Unauthorised Action" %]
- You are not authorised to edit attachments on bug [% bug_id %].
+ You are not authorised to edit attachments on [% terms.bug %] [%+ bug_id %].
[% ELSIF error == "illegal_attachment_is_patch" %]
[% title = "Your Query Makes No Sense" %]
@@ -246,7 +249,7 @@
You tried to change the [% field %] field
from [% oldvalue FILTER html %] to
[% newvalue FILTER html %],
- but only the owner or submitter of the bug, or a
+ but only the owner or submitter of the [% terms.bug %], or a
sufficiently empowered user, may change that field.
[% ELSIF error == "illegal_changed_in_last_x_days" %]
@@ -304,25 +307,27 @@
[% ELSIF error == "insufficient_privs_for_multi" %]
[% title = "Insufficient Privileges" %]
- Sorry, you do not have sufficient privileges to edit multiple bugs.
+ Sorry, you do not have sufficient privileges to edit multiple
+ [% terms.bugs %].
[% ELSIF error == "invalid_attach_id" %]
[% title = "Invalid Attachment ID" %]
The attachment id [% attach_id FILTER html %] is invalid.
[% ELSIF error == "invalid_bug_id" %]
- [% title = "Invalid Bug ID" %]
- The bug id [% bug_id FILTER html %] is invalid.
+ [% title = BLOCK %]Invalid [% terms.Bug %] ID[% END %]
+ The [% terms.bug %] id [% bug_id FILTER html %] is invalid.
[% ELSIF error == "invalid_bug_id_non_existent" %]
- [% title = "Invalid Bug ID" %]
- Bug #[% bug_id %] does not exist.
+ [% title = BLOCK %]Invalid [% terms.Bug %] ID[% END %]
+ [% terms.Bug %] #[% bug_id %] does not exist.
[% ELSIF error == "invalid_bug_id_or_alias" %]
- [% title = "Invalid Bug ID" %]
- The 'bug number' [% bug_id FILTER html %] is invalid.
+ [% title = BLOCK %]Invalid [% terms.Bug %] ID[% END %]
+ The '[% terms.bug %] number' [% bug_id FILTER html %] is invalid.
[% IF Param("usebugaliases") %]
- It is neither a bug number nor an alias to a bug number.
+ It is neither [% terms.abug %] number nor an alias to [% terms.abug %]
+ number.
[% END %]
If you are trying to use QuickSearch, you need to enable JavaScript
in your browser. To help us fix this limitation, add your comments to
@@ -336,10 +341,10 @@
[% ELSIF error == "invalid_content_type" %]
[% title = "Invalid Content-Type" %]
The content type [% contenttype FILTER html %] is invalid.
- Valid types must be of the form foo/bar where foo
- is either application, audio, image, message, model, multipart,
+ Valid types must be of the form foo/bar where foo
+ is either application, audio, image, message, model, multipart,
text, or video.
-
+
[% ELSIF error == "invalid_maxrow" %]
[% title = "Invalid Max Rows" %]
The maximum number of rows, '[% maxrows FILTER html %]', must be a positive
@@ -353,7 +358,7 @@
[% title = "Invalid Username" %]
The name [% name FILTER html %] is not a valid username.
Either you misspelled it, or the person has not
- registered for a Bugzilla account.
+ registered for a [% terms.Bugzilla %] account.
[% ELSIF error == "invalid_username_or_password" %]
[% title = "Invalid Username Or Password" %]
@@ -365,9 +370,9 @@
[% ELSIF error == "milestone_required" %]
[% title = "Milestone Required" %]
- You must determine a target milestone for bug [% bug_id %]
+ You must determine a target milestone for [% terms.bug %] [%+ bug_id %]
if you are going to accept it. Part of accepting
- a bug is giving an estimate of when it will be fixed.
+ [% terms.abug %] is giving an estimate of when it will be fixed.
[% ELSIF error == "misarranged_dates" %]
[% title = "Misarranged Dates" %]
@@ -384,7 +389,7 @@
[% ELSIF error == "missing_content_type" %]
[% title = "Missing Content-Type" %]
- You asked Bugzilla to auto-detect the content type, but
+ You asked [% terms.Bugzilla %] to auto-detect the content type, but
your browser did not specify a content type when uploading the file,
so you must enter a content type manually.
@@ -428,7 +433,8 @@
[% ELSIF error == "need_component" %]
[% title = "Component Required" %]
- You must specify a component to help determine the new owner of these bugs.
+ You must specify a component to help determine the new owner of these
+ [% terms.bugs %].
[% ELSIF error == "need_numeric_value" %]
[% title = "Numeric Value Required" %]
@@ -440,8 +446,8 @@
[% ELSIF error == "need_product" %]
[% title = "Product Required" %]
- You must specify a product to help determine the new owner of these bugs.
-
+ You must specify a product to help determine the new owner of these [% terms.bugs %].
+
[% ELSIF error == "need_quip" %]
[% title = "Quip Required" %]
Please enter a quip in the text field.
@@ -449,35 +455,35 @@
[% ELSIF error == "new_password_missing" %]
[% title = "New Password Missing" %]
You must enter a new password.
-
+
[% ELSIF error == "no_axes_defined" %]
[% title = "No Axes Defined" %]
You didn't define any axes to plot.
[% ELSIF error == "no_bugs_chosen" %]
- [% title = "No Bugs Chosen" %]
- You apparently didn't choose any bugs to modify.
+ [% title = BLOCK %]No [% terms.Bugs %] Chosen[% END %]
+ You apparently didn't choose any [% terms.bugs %] to modify.
[% ELSIF error == "no_component_change_for_multiple_products" %]
[% title = "Action Not Permitted" %]
- You cannot change the component for a list of bugs covering more than
+ You cannot change the component for a list of [% terms.bugs %] covering more than
one product.
-
+
[% ELSIF error == "no_components" %]
[% title = "No Components" %]
- Sorry; there needs to be at least one component for this product in order
- to create a new bug.
+ Sorry; there needs to be at least one component for this product in order
+ to create a new [% terms.bug %].
[% IF UserInGroup("editcomponents") %]
- Create a new component.
+ Create a new component.
[% ELSE %]
- Please contact [% Param("maintainer") %], giving the name of
- the product in which you tried to create a new bug.
+ Please contact [% Param("maintainer") %], giving the name of
+ the product in which you tried to create a new [% terms.bug %].
[% END %]
-
+
[% ELSIF error == "no_dupe_stats" %]
[% title = "Cannot Find Duplicate Statistics" %]
There are no duplicate statistics for today ([% today %]) or yesterday.
-
+
[% ELSIF error == "no_dupe_stats_error_today" %]
[% title = "Error Reading Today's Dupes File" %]
An error occurred opening today's dupes file: [% error_msg FILTER html %].
@@ -487,66 +493,66 @@
An error occurred opening [% changedsince FILTER html %] days ago
([% whenever FILTER html %])'s dupes file:
[% error_msg FILTER html %].
-
+
[% ELSIF error == "no_dupe_stats_error_yesterday" %]
[% title = "Error Reading Yesterday's Dupes File" %]
There are no duplicate statistics for today ([% today %]), and an error
occurred opening yesterday's dupes file: [% error_msg FILTER html %].
-
+
[% ELSIF error == "no_html_in_quips" %]
[% title = "No HTML In Quips" %]
- Sorry - for security reasons, support for HTML tags has been turned off
+ Sorry - for security reasons, support for HTML tags has been turned off
in quips.
-
+
[% ELSIF error == "no_new_quips" %]
[% title = "No New Quips" %]
This site does not permit the addition of new quips.
-
+
[% ELSIF error == "no_page_specified" %]
[% title = "No Page Specified" %]
You did not specify the id of a page to display.
[% ELSIF error == "no_products" %]
[% title = "No Products" %]
- Either no products have been defined to enter bugs against or you have not
+ Either no products have been defined to enter [% terms.bugs %] against or you have not
been given access to any.
-
+
[% ELSIF error == "old_password_incorrect" %]
[% title = "Incorrect Old Password" %]
You did not enter your old password correctly.
-
+
[% ELSIF error == "old_password_required" %]
[% title = "Old Password Required" %]
You must enter your old password to change email address.
-
+
[% ELSIF error == "passwords_dont_match" %]
[% title = "Passwords Don't Match" %]
The two passwords you entered did not match.
-
+
[% ELSIF error == "password_too_long" %]
[% title = "Password Too Long" %]
- The password is more than 16 characters long. It must be no more than
+ The password is more than 16 characters long. It must be no more than
16 characters.
-
+
[% ELSIF error == "password_too_short" %]
[% title = "Password Too Short" %]
- The password is less than three characters long. It must be at least
+ The password is less than three characters long. It must be at least
three characters.
-
+
[% ELSIF error == "patch_too_large" %]
[% title = "File Too Large" %]
The file you are trying to attach is [% filesize %] kilobytes (KB) in size.
Patches cannot be more than [% Param('maxpatchsize') %] KB in size.
- Try breaking your patch into several pieces.
+ Try breaking your patch into several pieces.
[% ELSIF error == "product_access_denied" %]
[% title = "Access Denied" %]
You do not have the permissions necessary to access that product.
-
+
[% ELSIF error == "product_edit_denied" %]
[% title = "Product Edit Access Denied" %]
- You are not permitted to edit bugs in product [% product %].
-
+ You are not permitted to edit [% terms.bugs %] in product [% product %].
+
[% ELSIF error == "query_name_missing" %]
[% title = "No Query Name Specified" %]
You must enter a name for your query.
@@ -561,8 +567,8 @@
[% ELSIF error == "reassign_to_empty" %]
[% title = "Illegal Reassignment" %]
- You cannot reassign to a bug to nobody. Unless you
- intentionally cleared out the "Reassign bug to"
+ You cannot reassign to [% terms.abug %] to nobody. Unless you
+ intentionally cleared out the "Reassign [% terms.bug %] to"
field, [% Param("browserbugmessage") %]
[% ELSIF error == "report_access_denied" %]
@@ -571,42 +577,42 @@
[% ELSIF error == "require_component" %]
[% title = "Component Needed" %]
- You must choose a component to file this bug in. If necessary,
+ You must choose a component to file this [% terms.bug %] in. If necessary,
just guess.
-
+
[% ELSIF error == "require_new_password" %]
[% title = "New Password Needed" %]
You cannot change your password without submitting a new one.
[% ELSIF error == "require_summary" %]
[% title = "Summary Needed" %]
- You must enter a summary for this bug.
-
+ You must enter a summary for this [% terms.bug %].
+
[% ELSIF error == "resolving_remaining_time" %]
[% title = "Trying to Resolve with Hours Remaining" %]
- You cannot resolve a bug with hours still remaining. Set
- Remaining Hours to zero if you want to resolve the bug.
+ You cannot resolve [% terms.abug %] with hours still remaining. Set
+ Remaining Hours to zero if you want to resolve the [% terms.bug %].
[% ELSIF error == "sanity_check_access_denied" %]
[% title = "Access Denied" %]
You do not have the permissions necessary to run a sanity check.
-
+
[% ELSIF error == "sidebar_supports_mozilla_only" %]
Sorry - sidebar.cgi currently only supports Mozilla based web browsers.
Upgrade today. :-)
[% ELSIF error == "too_many_votes_for_bug" %]
[% title = "Illegal Vote" %]
- You may only use at most [% max %] votes for a single bug in the
- [% prod FILTER html %] product, but you are trying to use
+ You may only use at most [% max %] votes for a single [% terms.bug %] in the
+ [% prod FILTER html %] product, but you are trying to use
[% votes %].
-
+
[% ELSIF error == "too_many_votes_for_product" %]
[% title = "Illegal Vote" %]
- You may only use at most [% max %] votes for bugs in the
- [% prod FILTER html %] product, but you are trying to use
+ You may only use at most [% max %] votes for [% terms.bugs %] in the
+ [% prod FILTER html %] product, but you are trying to use
[% votes %].
-
+
[% ELSIF error == "token_inexistent" %]
[% title = "Token Does Not Exist" %]
The token you submitted does not exist, has expired, or has
@@ -614,17 +620,17 @@
[% ELSIF error == "unknown_keyword" %]
[% title = "Unknown Keyword" %]
- [% keyword FILTER html %]
is not a known keyword.
+ [% keyword FILTER html %]
is not a known keyword.
The legal keyword names are listed here.
[% ELSIF error == "unknown_tab" %]
[% title = "Unknown Tab" %]
[% current_tab_name FILTER html %]
is not a legal tab name.
-
+
[% ELSIF error == "votes_must_be_nonnegative" %]
[% title = "Votes Must Be Non-negative" %]
- Only use non-negative numbers for your bug votes.
-
+ Only use non-negative numbers for your [% terms.bug %] votes.
+
[% ELSIF error == "wrong_token_for_cancelling_email_change" %]
[% title = "Wrong Token" %]
That token cannot be used to cancel an email address change.
@@ -644,7 +650,7 @@
[% ELSIF error == "zero_length_file" %]
[% title = "File Is Empty" %]
The file you are trying to attach is empty!
-
+
[% ELSE %]
[% title = "Error string not found" %]
The user error string [% error FILTER html %]
was not found.
diff --git a/template/en/default/global/variables.none.tmpl b/template/en/default/global/variables.none.tmpl
new file mode 100644
index 000000000..c63d1bf60
--- /dev/null
+++ b/template/en/default/global/variables.none.tmpl
@@ -0,0 +1,44 @@
+[%# 1.0@bugzilla.org %]
+[%# The contents of this file are subject to the Mozilla Public
+ # License Version 1.1 (the "License"); you may not use this file
+ # except in compliance with the License. You may obtain a copy of
+ # the License at http://www.mozilla.org/MPL/
+ #
+ # Software distributed under the License is distributed on an "AS
+ # IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
+ # implied. See the License for the specific language governing
+ # rights and limitations under the License.
+ #
+ # The Original Code is the Bugzilla Bug Tracking System.
+ #
+ # The Initial Developer of the Original Code is Netscape Communications
+ # Corporation. Portions created by Netscape are
+ # Copyright (C) 1998 Netscape Communications Corporation. All
+ # Rights Reserved.
+ #
+ # Contributor(s):
+ #%]
+
+[%# This is a list of terms that may be changed to "brand" the Bugzilla
+ # instance (for example, referring to "bugs" as "issues".) When used, these
+ # strings are used in several different types of content, and are not
+ # protected with Template-Toolkit FILTERs. Consequently, no special
+ # characters are allowed.
+ #
+ # Remember to PROCESS rather than INCLUDE this template.
+ #%]
+
+[% terms = {
+ "bug" => "bug",
+ "Bug" => "Bug",
+ "abug" = "a bug",
+ "Abug" = "A bug",
+ "ABug" = "A Bug",
+ "bugs" = "bugs",
+ "Bugs" = "Bugs",
+ "zeroSearchResults" = "Zarro Boogs found",
+ "bit" = "bit",
+ "bits" = "bits",
+ "Bugzilla" = "Bugzilla"
+ }
+%]
--
cgit v1.2.3-24-g4f1b