From f55027e7a07f4cb3f74cd6c42e710e794564df3c Mon Sep 17 00:00:00 2001 From: "myk%mozilla.org" <> Date: Sat, 30 Jul 2005 07:41:09 +0000 Subject: Fix for bug 302702: refactors tabs code into shared file so not only prefs and search but also other pages can use it --- template/en/default/search/tabs.html.tmpl | 39 +++++++------------------------ 1 file changed, 8 insertions(+), 31 deletions(-) (limited to 'template/en/default/search/tabs.html.tmpl') diff --git a/template/en/default/search/tabs.html.tmpl b/template/en/default/search/tabs.html.tmpl index 06b22f7a2..00358cb59 100644 --- a/template/en/default/search/tabs.html.tmpl +++ b/template/en/default/search/tabs.html.tmpl @@ -21,36 +21,13 @@ #%] [%# INTERFACE: - # tabs: List of hashes. May not be empty. Each hash has two members: - # name: string. Name of the tab and the format it represents. - # description: string. Description of the tab (used in tab title). + # This template has no interface. #%] -[% tabs = [ { name => 'specific', description => "Find a Specific $terms.Bug " }, - { name => 'advanced', description => "Advanced Search" } ] %] - -[% current_tab = query_format || format || "advanced" %] - -
- - - - - [% FOREACH tab = tabs %] - [% IF tab.name == current_tab %] - - [% ELSE %] - - [% END %] - [% END %] - - - -
  - [% tab.description %] - - - [% tab.description %] - -  
-
+[% PROCESS global/tabs.html.tmpl + tabs = [ { name => 'specific', label => "Find a Specific $terms.Bug", + link => "query.cgi?format=specific" }, + { name => 'advanced', label => "Advanced Search", + link => "query.cgi?format=advanced" } ] + current_tab_name = query_format || format || "advanced" +%] -- cgit v1.2.3-24-g4f1b