diff options
| author | hugetoad <hugetoad@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2005-09-08 17:02:02 +0000 |
|---|---|---|
| committer | hugetoad <hugetoad@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2005-09-08 17:02:02 +0000 |
| commit | 383f0f805ae778253c9ccdaf4b7531f7427515f8 (patch) | |
| tree | 575b332d9be833566fac80531595b9edc065b781 /frontends/php/include/forms.inc.php | |
| parent | 1d1a544dbef0e1ec664925cb085bb48ec42069d1 (diff) | |
| download | zabbix-383f0f805ae778253c9ccdaf4b7531f7427515f8.tar.gz zabbix-383f0f805ae778253c9ccdaf4b7531f7427515f8.tar.xz zabbix-383f0f805ae778253c9ccdaf4b7531f7427515f8.zip | |
Minor changes.
git-svn-id: svn://svn.zabbix.com/trunk@2057 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'frontends/php/include/forms.inc.php')
| -rw-r--r-- | frontends/php/include/forms.inc.php | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/frontends/php/include/forms.inc.php b/frontends/php/include/forms.inc.php index 4fdb0bc1..46fe70bb 100644 --- a/frontends/php/include/forms.inc.php +++ b/frontends/php/include/forms.inc.php @@ -1293,7 +1293,7 @@ } # Insert host profile form - function insert_host_profile_form($hostid) + function insert_host_profile_form($hostid,$readonly=0) { $selected=0; @@ -1341,7 +1341,10 @@ show_table2_v_delimiter($col++); echo "<form method=\"get\" action=\"hosts.php\">"; - echo "<input class=\"biginput\" name=\"config\" type=\"hidden\" value=\"".$_GET["config"]."\" size=8>"; + if(isset($_GET["config"])) + { + echo "<input class=\"biginput\" name=\"config\" type=\"hidden\" value=\"".$_GET["config"]."\" size=8>"; + } echo "<input class=\"biginput\" name=\"hostid\" type=\"hidden\" value=\"$hostid\" size=8>"; echo S_DEVICE_TYPE; @@ -1399,11 +1402,18 @@ echo form_textarea("notes",$notes,50,4); show_table2_v_delimiter2($col++); - echo "<input class=\"button\" type=\"submit\" name=\"register\" value=\"add profile\">"; - if(isset($hostid)) + if($readonly==0) { - echo "<input class=\"button\" type=\"submit\" name=\"register\" value=\"update profile\">"; - echo "<input class=\"button\" type=\"submit\" name=\"register\" value=\"delete profile\" onClick=\"return Confirm('Delete selected profile?');\">"; + echo "<input class=\"button\" type=\"submit\" name=\"register\" value=\"add profile\">"; + if(isset($hostid)) + { + echo "<input class=\"button\" type=\"submit\" name=\"register\" value=\"update profile\">"; + echo "<input class=\"button\" type=\"submit\" name=\"register\" value=\"delete profile\" onClick=\"return Confirm('Delete selected profile?');\">"; + } + } + else + { + echo " "; } show_table2_header_end(); |
