]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 294802: Make admin/table.html.tmpl replace multiple occurrances of %%column%%
authorbugreport%peshkin.net <>
Tue, 31 May 2005 22:42:44 +0000 (22:42 +0000)
committerbugreport%peshkin.net <>
Tue, 31 May 2005 22:42:44 +0000 (22:42 +0000)
Patch by dmelentyev
r=joel, a=justdave

template/en/default/admin/table.html.tmpl

index 4254f80e19cd22c03a73941c5ebb7e6a04172f1f..ff554429a009ba54b5691ba251fe3340d1e68a60 100644 (file)
       
         [% IF c.contentlink %]
           [% link_uri = c.contentlink %]
-          [% FOREACH m = link_uri.match('%%(.+?)%%'); %]
-            [% IF row.$m %]
-              [% replacement_value = FILTER url_quote; row.$m; END %]
+          [% WHILE link_uri.search('%%(.+?)%%')%]
+            [% FOREACH m = link_uri.match('%%(.+?)%%') %]
+              [% IF row.$m %]
+                [% replacement_value = FILTER url_quote; row.$m; END %]
+              [% ELSE %]
+                [% replacement_value = "" %]
+              [% END %]
               [% link_uri = link_uri.replace("%%$m%%", replacement_value) %]
             [% END %]
           [% END %]