home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.f-secure.com
/
2014.06.ftp.f-secure.com.tar
/
ftp.f-secure.com
/
support
/
hotfix
/
fsav-server
/
FSAVSRV900_HF07.fsfix
/
iuwebui
/
forms
/
tree_updates
/
autoupdates-pm.php
< prev
next >
Wrap
PHP Script
|
2010-09-07
|
4KB
|
106 lines
<?php
include ("..\common\commonphp.php");
$Page_Settings = array( array(oid => '1.3.6.1.4.1.2213.42.1.11.20.50', type => GLOBAL_TBL));
$tab_name = "tabAUAPM";
if(!isset($_POST[SUBMIT_TABLE]))
{
/* first load of the page */
readSettings(&$Page_Settings);
}
else
{
if($_POST[RESTORE_TABLE] == 1)
{
/* user wants to restore defaults */
readDefaultSettings(&$Page_Settings);
}
else
{
readSettings(&$Page_Settings);
if($_POST[REMOVE_ITEM] != -1)
unset($Page_Settings[0][value][$_POST[REMOVE_ITEM]]);
if($_POST[SUBMIT_TABLE] == 1)
writeSettings($Page_Settings);
}
exit(0);
}
show_form_management($tab_name, 1);
?>
<script language="javascript">
tabAUAPM_remove_hit = function(item_index)
{
refreshed = true;
document.form_tabAUAPM.REMOVE_ITEM.value = item_index;
document.form_tabAUAPM.SUBMIT_TABLE.value = 1;
dojo.byId("tabAUAPM_submitit").click();
}
dojo.byId('lists_dialog').style.background="#f3f3f3";
</script>
<form method="POST" action='<?php echo "{$_SERVER['PHP_SELF']}?{$_SERVER['QUERY_STRING']}";?>' id="form_<?php echo $tab_name;?>" name="form_<?php echo $tab_name;?>" style="padding: 0; margin: 0;">
<input type="hidden" name="SUBMIT_TABLE" value="0">
<input type="hidden" name="RESTORE_TABLE" value="0">
<input type="hidden" name="APPLY_SETTINGS" value="0">
<input type="hidden" name="REMOVE_ITEM" value="-1">
<button style='display:none' type='submit' id='tabAUAPM_submitit'></button>
<?php show_action_menu('Policy Manager Proxies', $tab_name); ?>
<table border="0" cellspacing="5" cellpadding="0" class="main_page_table">
<tr>
<td valign="top" width="100%">
<p style='margin: 0; padding-top: 5px'>
<table width=100% style='table-layout:fixed;' border=0 cellpadding=0 cellspacing=0>
<tr>
<td width="10px"><div class="table_stats_heading"><img src="../pics/layout/corner_up_left.gif" alt="" class="left_top"/></div></td>
<td align="left" width=100%><div class="table_stats_heading"><span><?=fsloc("Proxy address")?></span></div></td>
<td align="right" width=210><div class="table_stats_heading"><span><?=fsloc("Priority")?></span></div></td>
<td align="right" width=280><div class="table_stats_heading">
<span><?php if($global_can_edit && !isset($Page_Settings[0][lock])) echo ('<a id="tabAUAPM: add proxy" href="javascript:;" class="addtableitem" onClick="EnableExtraDialog(\'/tree_updates/popup_pm.php?NewItem\');">'.fsloc("Add new proxy...").'</a>');?></span>
</div></td>
<td width="10px"><div class="table_stats_heading"><img src="../pics/layout/corner_up_right.gif" alt="" class="right_top"/></div></td>
</tr>
<?php
{
if(count($Page_Settings[0][value]) == 0)
{
echo '</table>
<div class="tr_setting" style="padding-left: 15px;">' .
fsloc("No Policy Manager Proxy servers are specified.").'</div>';
}
else
{
$index = 0;
$tr_type = '';
foreach($Page_Settings[0][value] as $entry)
{
$tr_type = ($tr_type == '_odd') ? '_even' : '_odd';
$font_color = $entry[2] ? '' : ' color: #999999; ';
$remove_text = "<a id='tabAUAPM: remove {$index}' href='javascript:;' onClick='javascript: {$tab_name}_remove_hit({$index});'>".fsloc("remove")."</a>";
echo "
<tr class='tr_setting$tr_type'>
<td></td>
<td style='padding-left: 5px;'><a id='tabAUAPM: open {$index}' href='javascript:;' onClick='javascript: EnableExtraDialog(\"/tree_updates/popup_pm.php?EditItemFull&{$entry[1]}\");'>{$entry[1]}</a></td>
<td id='tabAUAPM: priority {$index}' align='right' style='padding-left: 10px; $font_color'>{$entry[0]}</td>
<td align='right' style='padding-left: 5px;'>$remove_text</td><td> </td>
</tr>
";
$index++;
}
echo '</table>';
}
}
?>
</td>
</tr>
<?php show_action_buttons($tab_name, true, true, false, false, true); ?>
</table>
</form>