summaryrefslogtreecommitdiffstats
path: root/frontends/php/sysmaps.php
diff options
context:
space:
mode:
authorhugetoad <hugetoad@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2006-01-03 10:03:54 +0000
committerhugetoad <hugetoad@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2006-01-03 10:03:54 +0000
commit26905a61d0cec458a04a971a6751e18a021d1c92 (patch)
tree5f601cc98feb07330cfc0ba280841929d1a042fe /frontends/php/sysmaps.php
parentbebbe1e18bdd25e6f976f8a39a308e65728b957d (diff)
downloadzabbix-26905a61d0cec458a04a971a6751e18a021d1c92.tar.gz
zabbix-26905a61d0cec458a04a971a6751e18a021d1c92.tar.xz
zabbix-26905a61d0cec458a04a971a6751e18a021d1c92.zip
PHP code cleanup. Use of class Ctable.
git-svn-id: svn://svn.zabbix.com/trunk@2484 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'frontends/php/sysmaps.php')
-rw-r--r--frontends/php/sysmaps.php16
1 files changed, 5 insertions, 11 deletions
diff --git a/frontends/php/sysmaps.php b/frontends/php/sysmaps.php
index 67f183a4..6c35e2bf 100644
--- a/frontends/php/sysmaps.php
+++ b/frontends/php/sysmaps.php
@@ -65,8 +65,8 @@
<?php
show_table_header("NETWORK MAPS");
- table_begin();
- table_header(array(S_ID,S_NAME,S_WIDTH,S_HEIGHT,S_ACTIONS));
+ $table = new Ctable(S_NO_MAPS_DEFINED);
+ $table->setHeader(array(S_ID,S_NAME,S_WIDTH,S_HEIGHT,S_ACTIONS));
$result=DBselect("select s.sysmapid,s.name,s.width,s.height from sysmaps s order by s.name");
$col=0;
@@ -77,21 +77,15 @@
continue;
}
- table_row(array(
+ $table->addRow(array(
$row["sysmapid"],
"<a href=\"sysmap.php?sysmapid=".$row["sysmapid"]."\">".$row["name"]."</a>",
$row["width"],
$row["height"],
"<A HREF=\"sysmaps.php?sysmapid=".$row["sysmapid"]."#form\">Change</A>"
- ),$col++);
+ ));
}
- if(DBnum_rows($result)==0)
- {
- echo "<TR BGCOLOR=#EEEEEE>";
- echo "<TD COLSPAN=5 ALIGN=CENTER>-No maps defined-</TD>";
- echo "<TR>";
- }
- table_end();
+ $table->show();
?>
<?php