]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Patch for bug 251596: show.html template should use customized body attribute; patch...
authorjocuri%softhome.net <>
Wed, 3 Nov 2004 06:54:12 +0000 (06:54 +0000)
committerjocuri%softhome.net <>
Wed, 3 Nov 2004 06:54:12 +0000 (06:54 +0000)
template/en/default/bug/show.html.tmpl
template/en/default/global/header.html.tmpl

index f98e05f0cbd87d4d5b62a5d07b0faaf8a33f52b7..8db59a9800444047e56d2f65e1af68e119fdffa3 100644 (file)
 
 [% filtered_desc = bug.short_desc FILTER html %]
 [% filtered_timestamp = bug.delta_ts FILTER time %]
-[% bodyattrs = BLOCK %]class='bz_bug bz_status_[% bug.bug_status 
-  FILTER css_class_quote %] bz_component_[% bug.component 
-  FILTER css_class_quote %] bz_bug_[% bug.bug_id 
-  FILTER css_class_quote %]' 
-[% END %]
 [% PROCESS global/header.html.tmpl
   title = "$terms.Bug $bug.bug_id - $bug.short_desc"
   h1 = "$terms.Bugzilla $terms.Bug $bug.bug_id"
   h2 = filtered_desc
   h3 = "Last modified: $filtered_timestamp"
-  bodyattrs = bodyattrs
+  bodyclasses = ['bz_bug',
+                 "bz_status_$bug.bug_status",
+                 "bz_component_$bug.component",
+                 "bz_bug_$bug.bug_id"
+                ]
 %]
 
 [% PROCESS bug/navigate.html.tmpl %]
index 5ee8c7f321acbf8a07818ee1dd0a2fe843b70210..ff283396fa27e19e4f9a5f4e4492b8c59f50924e 100644 (file)
@@ -28,6 +28,7 @@
   # h3: string. Right-aligned subheader.
   # bgcolor: string. the page's background color ("#rrggbb").
   # bodyattrs: any extra attributes for the <body> tag
+  # bodyclasses: array of extra CSS classes for the <body>
   # onload: string. JavaScript code to run when the page finishes loading.
   # javascript: string. Javascript to go in the header.
   # style: string. CSS style.
   #%]
 
   <body bgcolor="[% bgcolor %]" onload="[% onload %]"
-   class="[% Param('urlbase').replace('^https?://','').replace('/$','').replace('[-~@:/.]+','-') %]" 
-   [% bodyattrs %]>
+        class="[% Param('urlbase').replace('^https?://','').replace('/$','').replace('[-~@:/.]+','-') %]
+               [% FOREACH class = bodyclasses %]
+                 [% ' ' %][% class FILTER css_class_quote %]
+               [% END %]"
+        [% bodyattrs %]>
 
 [%# Migration note: the following file corresponds to the old Param
   # 'bannerhtml'