Changeset 1685

Show
Ignore:
Timestamp:
11/14/08 11:51:40 (2 months ago)
Author:
ton
Message:

Fix lots of links which were not going through c.uri_for

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/DEV-opsview3/opsview-web/root/admin/contact/edit_form_fields

    r1498 r1685  
    228228  default => 1440, 
    229229  help_keyword => "atom_feed", 
    230   help => 'Maximum number of minutes to keep items in the feed (equals <span id="normalise_minutes_info"></span>).<img src="/images/indicator.gif" alt="Indicator" style="display:none" id="normalise_minutes_indicator" />' 
     230  help => 'Maximum number of minutes to keep items in the feed (equals <span id="normalise_minutes_info"></span>).<img src="[% c.uri_for("/images/indicator.gif") %]" alt="Indicator" style="display:none" id="normalise_minutes_indicator" />' 
    231231  onblur => "display_minutes();", 
    232232  onkeypress => "return blockInvalidKeys(event,7);", 
  • branches/DEV-opsview3/opsview-web/root/admin/edit_functions_base

    r1473 r1685  
    88<div class="fields"> 
    99<h3> 
    10 <a href="#" onclick="return toggle_section('[% name %]')"><img src="/images/dots_expand.gif" alt="+" width="12" height="12" /></a>  
     10<a href="#" onclick="return toggle_section('[% name %]')"><img src="[% c.uri_for("/images/dots_expand.gif") %]" alt="+" width="12" height="12" /></a>  
    1111<a href="#" onclick="return toggle_section('[% name %]')">[% form_label %]</a> 
    1212</h3> 
     
    104104    eln = args.id || args.name; 
    105105    %]<div class="action" onclick="run_ajax_action('[% ajax.action %]',$('[% eln %]'))">[% ajax.text %]</div> 
    106 <img src="/images/indicator.gif" alt="Indicator" style="display:none" id="[% ajax.action %]_indicator" /> 
     106<img src="[% c.uri_for("/images/indicator.gif") %]" alt="Indicator" style="display:none" id="[% ajax.action %]_indicator" /> 
    107107<span id="[% ajax.action %]_info"></span>[% 
    108108  END; 
     
    152152       id = ' id="' _ args.name _ '_indicator"'; 
    153153    END; 
    154     '<img src="/images/indicator.gif" alt="Indicator" style="display:none"'; id; ' />'; 
     154    %]<img src="[% c.uri_for("/images/indicator.gif") %]" alt="Indicator" style="display:none"'; id; ' />[% 
    155155  END; 
    156156  IF args.help; 
     
    176176  <div class="autocomplete" id="[% args.name %]_auto_complete"></div> 
    177177  <script type="text/javascript"> 
    178     new Ajax.Autocompleter('[% args.name %]', '[% args.name %]_auto_complete', '/admin/ajax/autocomplete_[% args.autocomplete %]', {indicator:'[% args.name %]_auto_complete_indicator'}); 
     178    new Ajax.Autocompleter('[% args.name %]', '[% args.name %]_auto_complete', '[% c.uri_for("/admin/ajax/autocomplete_" _ args.autocomplete) %]', {indicator:'[% args.name %]_auto_complete_indicator'}); 
    179179  </script> 
    180   <img src="/images/indicator.gif" alt="Indicator" style="display:none" id="[% args.name %]_auto_complete_indicator" /> 
     180  <img src="[% c.uri_for("/images/indicator.gif") %]" alt="Indicator" style="display:none" id="[% args.name %]_auto_complete_indicator" /> 
    181181  [% END; 
    182182END; 
  • branches/DEV-opsview3/opsview-web/root/admin/graph/edit_form_fields

    r915 r1685  
    6060); 
    6161 
    62 '<img src="/images/indicator.gif" alt="Indicator" style="display:none" id="servicecheck_indicator" />'; 
     62%]<img src="[% c.uri_for("/images/indicator.gif") %]" alt="Indicator" style="display:none" id="servicecheck_indicator" />[% 
    6363 
    6464IF servicecheck;         
     
    8080); 
    8181 
    82 '<img src="/images/indicator.gif" alt="Indicator" style="display:none" id="metric_indicator" />'; 
     82%]<img src="[% c.uri_for("/images/indicator.gif") %]" alt="Indicator" style="display:none" id="metric_indicator" />[% 
    8383 
    8484IF metric; 
  • branches/DEV-opsview3/opsview-web/root/admin/host/list_functions

    r1616 r1685  
    11[% 
     2 
     3PROCESS image_links; 
     4# Move uri_for outside of loop because expensive 
     5hosttemplate_base_url = c.uri_for("/admin/hosttemplate/edit") _ "/"; 
    26 
    37MACRO list_header BLOCK; 
     
    2428  <td width="20"> 
    2529  [%- IF object.icon -%] 
    26   <img src="/images/logos/[% object.icon.filename_jpg %]" class="logo" width="20" height="20" alt="[% object.icon.filename_jpg %]" title="[% object.icon.filename %]" /> 
     30  <img src="[% logos_base _ object.icon.filename_jpg %]" class="logo" width="20" height="20" alt="[% object.icon.filename_jpg %]" title="[% object.icon.filename %]" /> 
    2731  [%- END -%] 
    2832  </td><td width="20"> 
    29   <img id="menu_[% object.id %]" src="/images/menu.png" class="menu" alt="Menu" width="20" height="20" onclick="return ajax_menu(this,'[% c.uri_for("menu", object.id) %]')" /> 
     33  <img id="menu_[% object.id %]" src="[% menu_image %]" class="menu" alt="Menu" width="20" height="20" onclick="return ajax_menu(this,'[% c.uri_for("menu", object.id) %]')" /> 
    3034  </td></tr> 
    3135  </table> 
     
    4751  templates = object.hosttemplates_arrayref; 
    4852 
    49   # Move uri_for outside of loop because expensive 
    50   url = c.uri_for("/admin/hosttemplate/edit") _ "/"; 
    5153  FOREACH t IN templates; 
    52     '<a href="'; url ; t.id; '">'; t.name; "</a><br />"; 
     54    '<a href="'; hosttemplate_base_url ; t.id; '">'; t.name; "</a><br />"; 
    5355  END; 
    5456  "</td>\n"; 
  • branches/DEV-opsview3/opsview-web/root/admin/host/snmp

    r887 r1685  
    1717                } 
    1818                Element.show("query_host_indicator"); 
    19                 new Ajax.Updater('snmp_info', "/admin/host/query_host", { method:"post", parameters:pars+ms+hostid, onSuccess:function() { Element.hide("query_host_indicator")} } ); 
     19                new Ajax.Updater('snmp_info', "[% c.uri_for("/admin/host/query_host") %]", { method:"post", parameters:pars+ms+hostid, onSuccess:function() { Element.hide("query_host_indicator")} } ); 
    2020        } 
    2121} 
     
    9090<div id='interface_nagios_detail'> 
    9191<div class="helpline action" onclick="queryhost([% object.id %])">Query host</div> 
    92 <img src="/images/indicator.gif" alt="Indicator" style="display:none" id="query_host_indicator" /> 
     92<img src="[% c.uri_for("/images/indicator.gif") %]" alt="Indicator" style="display:none" id="query_host_indicator" /> 
    9393[% IF c.action.name == "edit" %] 
    9494<div id='snmpwalk_scan' class="action" onclick="poll('hostid=[% object.id %]')">SNMP walk</div> 
    9595<div id='snmpwalk_rescan' class="action" onclick="rescan('hostid=[% object.id %]')" style="display:none">Rescan</div> 
    96 <img src="/images/indicator.gif" alt="Indicator" style="display:none" id="snmpwalk_indicator" /> 
     96<img src="[% c.uri_for("/images/indicator.gif") %]" alt="Indicator" style="display:none" id="snmpwalk_indicator" /> 
    9797<span id="snmpwalk_info"></span> 
    9898[% END %] 
  • branches/DEV-opsview3/opsview-web/root/admin/host/tab-host

    r1572 r1685  
    44        if (ip && $('monitored_by')) { 
    55                Element.show('monitored_by_indicator'); 
    6                 new Ajax.Request( '/public/closest_monitoringserver/' + ip, { method: 'get', onSuccess:choose_ms }); 
     6                new Ajax.Request( '[% c.uri_for("/public/closest_monitoringserver") %]/' + ip, { method: 'get', onSuccess:choose_ms }); 
    77        } 
    88} 
     
    170170</label> 
    171171[% END; %] 
    172 </td><td><img src="/images/indicator.gif" alt="Indicator" style="display:none" id="parents_indicator" /> 
     172</td><td><img src="[% c.uri_for("/images/indicator.gif") %]" alt="Indicator" style="display:none" id="parents_indicator" /> 
    173173</td></tr></table> 
    174174<br /> 
  • branches/DEV-opsview3/opsview-web/root/admin/hostcheckcommands/edit_form_fields

    r915 r1685  
    2020  default => "check_tcp", 
    2121) %] 
    22 <img src="/images/indicator.gif" alt="Indicator" style="display:none" id="plugin_indicator" /> 
     22<img src="[% c.uri_for("/images/indicator.gif") %]" alt="Indicator" style="display:none" id="plugin_indicator" /> 
    2323<br /> 
    2424<div class="input"> 
  • branches/DEV-opsview3/opsview-web/root/admin/hostgroup/graph_diagram

    r1409 r1685  
    3333          # So we stop the menu icon from being drawn 
    3434          UNLESS useragent.search('MSIE\s+7') %] 
    35                 <span class="hhmenuicon"><img id="menu_icon_[% group.id %]" src="/images/menu.png" onclick="return ajax_menu(this,'[% c.uri_for("menu", group.id) %]')" class="menu" alt="Menu" width="20" height="20" /></span> 
     35                <span class="hhmenuicon"><img id="menu_icon_[% group.id %]" src="[% c.uri_for("/images/menu.png") %]" onclick="return ajax_menu(this,'[% c.uri_for("menu", group.id) %]')" class="menu" alt="Menu" width="20" height="20" /></span> 
    3636          [% END %] 
    3737        </div> 
  • branches/DEV-opsview3/opsview-web/root/admin/hypergraph/index

    r971 r1685  
    33        align="baseline" 
    44        archive="[% c.uri_for("/javascript/hyperapplet.jar") %]"  
    5         width="700
    6         height="700
     5        width="100%
     6        height="90%
    77> 
    88 
  • branches/DEV-opsview3/opsview-web/root/admin/reload/opsview

    r1682 r1685  
    170170</div> 
    171171<div id="reloading_gears" [% hide %]><div> 
    172  <img src="[% IF (c.config.reload_image); c.config.reload_image; ELSE; '/images/animated_gears.gif'; END; %]" alt="Reloading" /><br/> 
     172 <img src="[% IF (c.config.reload_image); c.uri_for(c.config.reload_image); ELSE; c.uri_for('/images/animated_gears.gif'); END; %]" alt="Reloading" /><br/> 
    173173 A reload will take about <span class="average_time">[% functions.parseInterval("seconds", average_time, "String", 1) %]</span><br/> 
    174174 <div class="spacer"></div> 
  • branches/DEV-opsview3/opsview-web/root/admin/report/list_functions

    r1409 r1685  
    1717    title="Edit [% IF object.name; object.name; ELSE; 'Unnamed'; END; %]">[% IF object.name; object.name; ELSE; 'Unnamed';END;  %]</a> 
    1818</td> 
    19 <td width="20"><img id="menu_[% object.id %]" src="/images/menu.png" class="menu" alt="Menu" width="20" height="20" onclick="return ajax_menu(this,'[% c.uri_for("menu", object.id) %]')" /></td> 
     19<td width="20"><img id="menu_[% object.id %]" src="[% c.uri_for("/images/menu.png") %]" class="menu" alt="Menu" width="20" height="20" onclick="return ajax_menu(this,'[% c.uri_for("menu", object.id) %]')" /></td> 
    2020</tr> 
    2121</table></td> 
  • branches/DEV-opsview3/opsview-web/root/admin/report/start_generate

    r1022 r1685  
    11<h2>[% c.loc("Generating report....") %]</h2> 
    2 <div id="info" class="centered" style="white-space: pre"><img src="/images/indicator.gif" alt="Indicator" id="generate_indicator"/></div> 
     2<div id="info" class="centered" style="white-space: pre"><img src="[% c.uri_for("/images/indicator.gif") %]" alt="Indicator" id="generate_indicator"/></div> 
    33<script type="text/javascript"> 
    44function poll_report() { 
  • branches/DEV-opsview3/opsview-web/root/admin/servicecheck/edit_form_fields

    r1611 r1685  
    232232  default => "check_tcp", 
    233233); 
    234 '<img src="/images/indicator.gif" alt="Indicator" style="display:none" id="plugin_indicator" />'; 
     234%]<img src="[% c.uri_for("/images/indicator.gif") %]" alt="Indicator" style="display:none" id="plugin_indicator" /> 
     235[% 
    235236checkbox( 
    236237  name => "invertresults", 
     
    361362<div class="autocomplete" id="example_host_auto_complete"></div> 
    362363<script type="text/javascript"> 
    363 new Ajax.Autocompleter('example_host', 'example_host_auto_complete', '/admin/host/autocomplete', {indicator:'snmpwalk_indicator'}); 
     364new Ajax.Autocompleter('example_host', 'example_host_auto_complete', '[% c.uri_for("/admin/host/autocomplete") %]', {indicator:'snmpwalk_indicator'}); 
    364365</script> 
    365366<div id='snmpwalk_scan' class="action" onclick="if (! $('example_host').value) alert('Must enter an example host'); else poll('host='+$('example_host').value)">SNMP walk</div> 
    366367<div id='snmpwalk_rescan' class="action" onclick="rescan('host='+$('example_host').value)" style="display:none">Rescan</div> 
    367 <img src="/images/indicator.gif" alt="Indicator" style="display:none" id="snmpwalk_indicator" /> 
     368<img src="[% c.uri_for("/images/indicator.gif") %]" alt="Indicator" style="display:none" id="snmpwalk_indicator" /> 
    368369<span id="snmpwalk_info"></span> 
    369370<br /> 
  • branches/DEV-opsview3/opsview-web/root/admin/servicecheck/list_functions

    r1409 r1685  
    11[% 
     2 
     3menu_image = c.uri_for("/images/menu.png"); 
    24 
    35MACRO list_header BLOCK; 
     
    1820   [% edit_link(object); %] 
    1921   <td width="20"> 
    20    <img id="menu_[% object.id %]" src="/images/menu.png" class="menu" alt="Menu" width="20" height="20" onclick="return ajax_menu(this,'[% c.uri_for("menu", object.id) %]')" /> 
     22   <img id="menu_[% object.id %]" src="[% menu_image %]" class="menu" alt="Menu" width="20" height="20" onclick="return ajax_menu(this,'[% c.uri_for("menu", object.id) %]')" /> 
    2123   </td></tr> 
    2224   </table> 
  • branches/DEV-opsview3/opsview-web/root/admin/snmptrap/tracing

    r357 r1685  
    4949<span class="action" onclick="collect()">Collect</span> 
    5050<br /> 
    51 <img src="/images/indicator.gif" alt="Indicator" style="display:none" id="collect_indicator" /> 
     51<img src="[% c.uri_for("/images/indicator.gif") %]" alt="Indicator" style="display:none" id="collect_indicator" /> 
    5252<br /> 
    5353<span id="collect_text"></span> 
     
    6060new Autocompleter.Local('hostname_add', 'hostname_auto_complete', ['[% hosts.join("','") %]'], { fullSearch: true }); 
    6161</script> 
    62 <img src="/images/indicator.gif" alt="Indicator" style="display:none" id="host_indicator" /> 
     62<img src="[% c.uri_for("/images/indicator.gif") %]" alt="Indicator" style="display:none" id="host_indicator" /> 
    6363</td> 
    6464</tr></table> 
  • branches/DEV-opsview3/opsview-web/root/admin/snmptrapexception/list_functions

    r950 r1685  
    44        if(!exception_id) return; 
    55 
    6         new Ajax.Request("/admin/snmptrapexception/poll_promote_mib/"+exception_id, { method:"post", onSuccess:function(t) { 
     6        new Ajax.Request("[% c.uri_for("/admin/snmptrapexception/poll_promote_mib") %]/"+exception_id, { method:"post", onSuccess:function(t) { 
    77                var json = t.responseText.evalJSON(true); 
    88                if(json) { 
     
    3737        if(!exception_id) return; 
    3838 
    39         new Ajax.Request("/admin/snmptrapexception/promote_mib/"+exception_id); 
     39        new Ajax.Request("[% c.uri_for("/admin/snmptrapexception/promote_mib") %]/"+exception_id); 
    4040        if($('promote_mib_indicator_'+exception_id).style.display=='none') 
    4141                Element.show("promote_mib_indicator_"+exception_id); 
     
    9595<input type="button" id="promote_mib_button_[% object.id %]" value="Promote mib" 
    9696        onclick="Element.show('promote_mib_indicator_[% object.id %]');$('promote_mib_[% object.id %]').innerHTML = 'MIB promotion in progress';Element.hide('promote_mib_button_[% object.id %]');promote_mib([% object.id %]);" /> 
    97 <img src="/images/indicator.gif" alt="Indicator" style="display:none" id="promote_mib_indicator_[% object.id %]" /> 
     97<img src="[% c.uri_for("/images/indicator.gif") %]" alt="Indicator" style="display:none" id="promote_mib_indicator_[% object.id %]" /> 
    9898<div id="promote_mib_[% object.id %]"></div> 
    9999[%-  
  • branches/DEV-opsview3/opsview-web/root/admin/snmptrapexception/list_layout

    r950 r1685  
    55<div class="blank-bar"><input type="button" class="left" value="Refresh" name="Refresh" onclick="window.location.reload()" /> 
    66  [% IF args.reprocess; %] 
    7 <input type="button" class="right" name="Re-process" value="Re-process" onclick="new Ajax.Request('/admin/snmptrapexception/reprocess'); alert('Reprocessing all traps. Click OK to reload'); window.location.reload()" /> 
     7<input type="button" class="right" name="Re-process" value="Re-process" onclick="new Ajax.Request('[% c.uri_for("/admin/snmptrapexception/reprocess") %]'); alert('Reprocessing all traps. Click OK to reload'); window.location.reload()" /> 
    88[% END; 
    99  "</div>"; 
  • branches/DEV-opsview3/opsview-web/root/admin/systempreference/tab-sms

    r1521 r1685  
    7777        Element.show('check_credit_indicator'); 
    7878        var pars = "username=" + $('aql_username').value + '&password=' + $('aql_password').value + '&proxy_server=' + $('aql_proxy_server').value; 
    79         new Ajax.Updater('check_credit_info', "/admin/ajax/check_credit", { method:"post", parameters:pars, onSuccess:function() { Element.hide("check_credit_indicator")} } ); 
     79        new Ajax.Updater('check_credit_info', "[% c.uri_for("/admin/ajax/check_credit") %]", { method:"post", parameters:pars, onSuccess:function() { Element.hide("check_credit_indicator")} } ); 
    8080} 
    8181</script> 
    8282<div class="action" onclick="check_credit(this.form)">Check credit</div> 
    83 <img src="/images/indicator.gif" alt="Indicator" style="display:none" id="check_credit_indicator" /> 
     83<img src="[% c.uri_for("/images/indicator.gif") %]" alt="Indicator" style="display:none" id="check_credit_indicator" /> 
    8484<span id="check_credit_info"></span> 
    8585</div> 
  • branches/DEV-opsview3/opsview-web/root/public/plugin_help

    r2 r1685  
    77    <title>[% title %]</title> 
    88    <link rel="stylesheet" type="text/css" 
    9       href="/stylesheets/opsview.css" /> 
     9      href="[% c.uri_for("/stylesheets/opsview.css") %]" /> 
    1010    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> 
    1111  </head> 
  • branches/DEV-opsview3/opsview-web/root/state/host/detail

    r1471 r1685  
    3737<td class="center [% class %]"> 
    3838[% IF obj.actual_start_time == "0000-00-00 00:00:00"; %] 
    39 <img alt="Downtime" src="/images/sched_downtime.gif" width="20" height="20" title="Scheduled Downtime" /> 
     39<img alt="Downtime" src="[% c.uri_for("/images/sched_downtime.gif") %]" width="20" height="20" title="Scheduled Downtime" /> 
    4040[% ELSE; %] 
    41 <img alt="Downtime" src="/images/downtime.gif" width="20" height="20" title="Downtime" /> 
     41<img alt="Downtime" src="[% c.uri_for("/images/downtime.gif") %]" width="20" height="20" title="Downtime" /> 
    4242[% END; %] 
    4343</td> 
  • branches/DEV-opsview3/opsview-web/root/state/host/menu

    r1678 r1685  
    1717[% IF opsview_host.use_nmis && c.user.role.fixedname == "admin"; 
    1818     IF ! opsview_host.monitored_by.is_master; 
    19         prefix = "http://" _ opsview_host.monitored_by.scalar.nodes.first.ip; 
     19        prefix = "http://" _ opsview_host.monitored_by.scalar.nodes.first.ip _ "/"; 
     20     ELSE; 
     21        prefix = c.uri_for("/"); 
    2022     END; 
    21 %]<a href="[% prefix _ "/cgi-nmis/nmiscgi.pl?node=" _ object.ip | html %]" alt="NMIS">NMIS</a><br/> 
     23%]<a href="[% prefix _ "cgi-nmis/nmiscgi.pl?node=" _ object.ip | html %]" alt="NMIS">NMIS</a><br/> 
    2224[% END %] 
    2325[% IF opsview_host.use_rancid && c.model("OpsviewDB::Applicationplugin").search( name => "rancid" ).count ; %] 
  • branches/DEV-opsview3/opsview-web/root/state/hostgroup/detail

    r1306 r1685  
    6767<td class="center [% class %]"> 
    6868[% IF obj.actual_start_time == "0000-00-00 00:00:00"; %] 
    69 <img alt="Downtime" src="/images/sched_downtime.gif" width="20" height="20" title="Scheduled Downtime" /> 
     69<img alt="Downtime" src="[% c.uri_for("/images/sched_downtime.gif") %]" width="20" height="20" title="Scheduled Downtime" /> 
    7070[% ELSE; %] 
    71 <img alt="Downtime" src="/images/downtime.gif" width="20" height="20" title="Downtime" /> 
     71<img alt="Downtime" src="[% c.uri_for("/images/downtime.gif") %]" width="20" height="20" title="Downtime" /> 
    7272[% END; %] 
    7373</td> 
  • branches/DEV-opsview3/opsview-web/root/state/hostgroup/list_downtime_hosts

    r1286 r1685  
    2020                        <td width="70" class="center [% class %]"> 
    2121                        [% IF obj.actual_start_time == "0000-00-00 00:00:00"; %] 
    22                         <img alt="Downtime" src="/images/sched_downtime.gif" width="20" height="20" title="Scheduled Downtime" /> 
     22                        <img alt="Downtime" src="[% c.uri_for("/images/sched_downtime.gif") %]" width="20" height="20" title="Scheduled Downtime" /> 
    2323                        [% ELSE; %] 
    24                         <img alt="Downtime" src="/images/downtime.gif" width="20" height="20" title="Downtime" /> 
     24                        <img alt="Downtime" src="[% c.uri_for("/images/downtime.gif") %]" width="20" height="20" title="Downtime" /> 
    2525                        [% END; %] 
    2626                        </td> 
  • branches/DEV-opsview3/opsview-web/root/state/hostgroup/list_downtime_services

    r1286 r1685  
    2222                        <td width="20" class="center [% class %]"> 
    2323                        [% IF obj.actual_start_time == "0000-00-00 00:00:00"; %] 
    24                         <img alt="Downtime" src="/images/sched_downtime.gif" width="20" height="20" title="Scheduled Downtime" /> 
     24                        <img alt="Downtime" src="[% c.uri_for("/images/sched_downtime.gif") %]" width="20" height="20" title="Scheduled Downtime" /> 
    2525                        [% ELSE; %] 
    26                         <img alt="Downtime" src="/images/downtime.gif" width="20" height="20" title="Downtime" /> 
     26                        <img alt="Downtime" src="[% c.uri_for("/images/downtime.gif") %]" width="20" height="20" title="Downtime" /> 
    2727                        [% END; %] 
    2828                        </td> 
  • branches/DEV-opsview3/opsview-web/root/state/service/detail

    r1471 r1685  
    3737<td class="center [% class %]"> 
    3838[% IF obj.actual_start_time == "0000-00-00 00:00:00"; %] 
    39 <img alt="Downtime" src="/images/sched_downtime.gif" width="20" height="20" title="Scheduled Downtime" /> 
     39<img alt="Downtime" src="[% c.uri_for("/images/sched_downtime.gif") %]" width="20" height="20" title="Scheduled Downtime" /> 
    4040[% ELSE; %] 
    41 <img alt="Downtime" src="/images/downtime.gif" width="20" height="20" title="Downtime" /> 
     41<img alt="Downtime" src="[% c.uri_for("/images/downtime.gif") %]" width="20" height="20" title="Downtime" /> 
    4242[% END; %] 
    4343</td> 
  • branches/DEV-opsview3/opsview-web/root/status/host

    r1409 r1685  
    4242   <a href="[% base_url _ "/host/name/" _ status.name _ "/detail" | html %]"> 
    4343   [% IF status.downtime == 1 %] 
    44    <img alt="Downtime" src="/images/sched_downtime.gif" width="20" height="20" title="Scheduled Downtime" /> 
     44   <img alt="Downtime" src="[% sched_downtime_image %]" width="20" height="20" title="Scheduled Downtime" /> 
    4545   [% ELSIF status.downtime == 2 %] 
    46    <img alt="Downtime" src="/images/downtime.gif" width="20" height="20" title="Downtime" /> 
     46   <img alt="Downtime" src="[% downtime_image %]" width="20" height="20" title="Downtime" /> 
    4747   [% END %] 
    4848   [% IF status.flapping %] 
    4949   </td><td width="20"> 
    5050   <a href="[% c.uri_for("/cgi-bin/extinfo.cgi", { type => 1, host => status.name }) _ "#comments" | html %]"> 
    51    <img alt="Flapping" src="/images/flapping.gif" width="20" height="20" title="Flapping"/> 
     51   <img alt="Flapping" src="[% flapping_image %]" width="20" height="20" title="Flapping"/> 
    5252   </a> 
    5353   [% END %] 
     
    5555   </td><td width="20"> 
    5656   <a href="[% c.uri_for("/cgi-bin/extinfo.cgi", { type => 1, host => status.name }) _ "#comments" | html %]"> 
    57    <img alt="Acknowledged" src="/images/ack.gif" width="20" height="20" title="Acknowledged"/> 
     57   <img alt="Acknowledged" src="[% ack_image %]" width="20" height="20" title="Acknowledged"/> 
    5858   </a> 
    5959   [% END %] 
     
    6161   </td><td width="20"> 
    6262   <a href="[% c.uri_for("/cgi-bin/extinfo.cgi", { type => 1, host => status.name }) _ "#comments" | html %]"> 
    63    <img alt="[% status.comments %] [% c.loc("Comment(s)") %]" src="/images/comment.gif" width="20" height="20" title="[% status.comments %] [% c.loc("Comment(s)") %]"/> 
     63   <img alt="[% status.comments %] [% c.loc("Comment(s)") %]" src="[% comment_image %]" width="20" height="20" title="[% status.comments %] [% c.loc("Comment(s)") %]"/> 
    6464   </a> 
    6565   [% END %] 
    6666   </td><td width="20"> 
    67    <img src="/images/logos/[% status.icon %].jpg" class="logo" width="20" height="20" alt="[% status.icon %]" title="[% status.icon %]" /> 
     67   <img src="[% logos_base _ status.icon _ ".jpg" | html %]" class="logo" width="20" height="20" alt="[% status.icon %]" title="[% status.icon %]" /> 
    6868   </td><td width="20"> 
    69    <img id="menu_[% status.name %]" class="menu" alt="Menu" src="/images/menu.png" width="20" height="20" 
     69   <img id="menu_[% status.name %]" class="menu" alt="Menu" src="[% menu_image %]" width="20" height="20" 
    7070      onclick="return ajax_menu(this,'[% base_url _ "/host/name/" _ status.name _ "/menus" | html %]')" /> 
    7171   </td></tr> 
  • branches/DEV-opsview3/opsview-web/root/status/hostgroup

    r1409 r1685  
    4646                        <a href="[% base_url _ "/hostgroup/" _ status.hostgroup_id _ "/detail" %]"> 
    4747      [% IF status.downtime == 1; %] 
    48         <img alt="Downtime" src="/images/sched_downtime.gif" width="20" height="20" title="Scheduled Downtime" /> 
     48        <img alt="Downtime" src="[% c.uri_for("/images/sched_downtime.gif") %]" width="20" height="20" title="Scheduled Downtime" /> 
    4949      [% ELSIF status.downtime == 2; %] 
    50         <img alt="Downtime" src="/images/downtime.gif" width="20" height="20" title="Downtime" /> 
     50        <img alt="Downtime" src="[% c.uri_for("/images/downtime.gif") %]" width="20" height="20" title="Downtime" /> 
    5151      [% END; %] 
    5252                        </a> 
     
    5454    </td> 
    5555    <td width="20"> 
    56      <img id="menu_[% status.hostgroup_id %]" class="menu" alt="Menu" src="/images/menu.png" width="20" height="20" 
     56     <img id="menu_[% status.hostgroup_id %]" class="menu" alt="Menu" src="[% c.uri_for("/images/menu.png") %]" width="20" height="20" 
    5757      onclick="return ajax_menu(this,'[% base_url _ "/hostgroup/" _ status.hostgroup_id _ "/menus" | html %]')" /> 
    5858    </td></tr> 
  • branches/DEV-opsview3/opsview-web/root/status/service

    r1591 r1685  
    6363                        <a href="[% base_url _ "/host/name/" _ host.name _ "/detail" | html %]"> 
    6464                        [% IF host.downtime == 1 %] 
    65                         <img alt="Downtime" src="/images/sched_downtime.gif" width="20" height="20" title="Scheduled Downtime" /> 
     65                        <img alt="Downtime" src="[% sched_downtime_image %]" width="20" height="20" title="Scheduled Downtime" /> 
    6666                        [% ELSIF host.downtime == 2 %] 
    67                         <img alt="Downtime" src="/images/downtime.gif" width="20" height="20" title="Downtime" /> 
     67                        <img alt="Downtime" src="[% downtime_image %]" width="20" height="20" title="Downtime" /> 
    6868                        [% END %] 
    6969                        </a> 
     
    7171      </td><td width="20"> 
    7272      <a href="[% c.uri_for("/cgi-bin/extinfo.cgi", { type => 1, host => host.name }) _ "#comments" | html %]"> 
    73       <img alt="Flapping" src="/images/flapping.gif" width="20" height="20" title="Flapping"/> 
     73      <img alt="Flapping" src="[% flapping_image %]" width="20" height="20" title="Flapping"/> 
    7474      </a> 
    7575      [% END %] 
     
    7777      </td><td width="20"> 
    7878      <a href="[% c.uri_for("/cgi-bin/extinfo.cgi", { type => 1, host => host.name }) _ "#comments" | html %]"> 
    79       <img alt="Acknowledged" src="/images/ack.gif" width="20" height="20" title="Acknowledged"/> 
     79      <img alt="Acknowledged" src="[% ack_image %]" width="20" height="20" title="Acknowledged"/> 
    8080      </a> 
    8181      [% END %] 
     
    8383      </td><td width="20"> 
    8484      <a href="[% c.uri_for("/cgi-bin/extinfo.cgi", { type => 1, host => host.name }) _ "#comments" | html %]"> 
    85       <img alt="[% host.comments %] [% c.loc("Comment(s)") %]" src="/images/comment.gif" width="20" height="20" title="[% host.comments %] [% c.loc("Comment(s)") %]"/> 
     85      <img alt="[% host.comments %] [% c.loc("Comment(s)") %]" src="[% comment_image %]" width="20" height="20" title="[% host.comments %] [% c.loc("Comment(s)") %]"/> 
    8686      </a> 
    8787      [% END %] 
    8888      </td><td width="20"> 
    89       <img src="/images/logos/[% host.icon %].jpg" class="logo" width="20" height="20" alt="[% host.icon %]" title="[% host.icon %]" /> 
     89      <img src="[% logos_base _  host.icon _ ".jpg" %]" class="logo" width="20" height="20" alt="[% host.icon %]" title="[% host.icon %]" /> 
    9090      </td><td width="20"> 
    91       <img id="menu_host_[% host.name %]" class="menu" alt="Menu" src="/images/menu.png" width="20" height="20" 
     91      <img id="menu_host_[% host.name %]" class="menu" alt="Menu" src="[% menu_image %]" width="20" height="20" 
    9292        onclick="return ajax_menu(this,'[% base_url _ "/host/name/" _ host.name _ "/menus" | html %]')" /> 
    9393      </td></tr> 
     
    114114                <a href="[% base_url _ "/service/" _ service.service_object_id _ "/detail" | html %]"> 
    115115                [% IF service.downtime == 1 %] 
    116                 <img alt="Downtime" src="/images/sched_downtime.gif" width="20" height="20" title="Scheduled Downtime" /> 
     116                <img alt="Downtime" src="[% sched_downtime_image %]" width="20" height="20" title="Scheduled Downtime" /> 
    117117                [% ELSIF service.downtime == 2 %] 
    118                 <img alt="Downtime" src="/images/downtime.gif" width="20" height="20" title="Downtime" /> 
     118                <img alt="Downtime" src="[% downtime_image %]" width="20" height="20" title="Downtime" /> 
    119119                [% END %] 
    120120                </a> 
     
    122122    </td><td width="20"> 
    123123    <a href="[% c.uri_for("/cgi-bin/extinfo.cgi", { type => 2, host => host.name, service => service.name }) _ "#comments" | html %]"> 
    124     <img alt="Flapping" src="/images/flapping.gif" width="20" height="20" title="Flapping"/> 
     124    <img alt="Flapping" src="[% flapping_image %]" width="20" height="20" title="Flapping"/> 
    125125    </a> 
    126126    [% END %] 
     
    128128    </td><td width="20"> 
    129129    <a href="[% c.uri_for("/cgi-bin/extinfo.cgi", { type => 2, host => host.name, service => service.name }) _ "#comments" | html %]"> 
    130     <img alt="Acknowledged" src="/images/ack.gif" width="20" height="20" title="Acknowledged"/> 
     130    <img alt="Acknowledged" src="[% ack_image %]" width="20" height="20" title="Acknowledged"/> 
    131131    </a> 
    132132    [% END %] 
     
    134134    </td><td width="20"> 
    135135    <a href="[% c.uri_for("/cgi-bin/extinfo.cgi", { type => 2, host => host.name, service => service.name }) _ "#comments" | html %]"> 
    136     <img alt="[% service.comments %] [% c.loc("Comment(s)") %]" src="/images/comment.gif" width="20" height="20" title="[% service.comments %] [% c.loc("Comment(s)") %]"/> 
     136    <img alt="[% service.comments %] [% c.loc("Comment(s)") %]" src="[% comment_image %]" width="20" height="20" title="[% service.comments %] [% c.loc("Comment(s)") %]"/> 
    137137    </a> 
    138138    [% END %] 
     
    140140    </td><td width="20"> 
    141141    <a href="[% c.uri_for("/cgi-bin/show.cgi", { host => host.name, service => service.name, fixedscale => 1 } ) | html %]"> 
    142     <img src="/images/logos/graph-icon.gif" border="0" width="20" height="20" alt="View graphs" title="View graphs" /></a> 
     142    <img src="[% graph_image %]" border="0" width="20" height="20" alt="View graphs" title="View graphs" /></a> 
    143143    [% END %] 
    144144    </td><td width="20"> 
    145     <img id="menu_service_[% service.service_object_id %]" class="menu" alt="Menu" src="/images/menu.png" width="20" height="20" 
     145    <img id="menu_service_[% service.service_object_id %]" class="menu" alt="Menu" src="[% menu_image %]" width="20" height="20" 
    146146      onclick="return ajax_menu(this,'[% base_url _ "/service/" _ service.service_object_id _ "/menus" | html %]')" /> 
    147147    </td></tr> 
  • branches/DEV-opsview3/opsview-web/root/status/status_functions

    r1612 r1685  
    22 
    33PROCESS object_info_base; 
     4PROCESS image_links; 
    45 
    56MACRO print_mini_status_host(type, url) BLOCK; 
  • branches/DEV-opsview3/opsview-web/root/wrappers/miniwindow

    r1521 r1685  
    44<head> 
    55  <title>[% page_title %]</title> 
    6   <link rel="stylesheet" type="text/css" href="/stylesheets/opsview2.css"> 
     6  <link rel="stylesheet" type="text/css" href="[% c.uri_for("/stylesheets/opsview2.css") %]"> 
    77  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> 
    88  [%- FOREACH script = c.stash.javascript %] 
    9   <script src="/javascript/[% script %]" type="text/javascript"></script> 
     9  <script src="[% c.uri_for("/javascript", script) %]" type="text/javascript"></script> 
    1010  [% END %] 
    1111</head>