Changeset 738 for trunk/Modules/NetworkTopology/NetworkTopology.php
- Timestamp:
- Apr 14, 2015, 10:20:16 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Modules/NetworkTopology/NetworkTopology.php
r586 r738 7 7 var $ParentClass = 'PagePortal'; 8 8 var $TopHostName = 'NIX-ROUTER'; 9 9 10 10 function Show() 11 11 { 12 12 if(count($this->System->PathItems) > 1) 13 { 13 { 14 14 if($this->System->PathItems[1] == 'topologie.png') return($this->ShowImage()); 15 15 else return(PAGE_NOT_FOUND); 16 16 17 17 } else return($this->ShowOverview()); 18 18 } 19 19 20 20 function ShowImage() 21 21 { … … 31 31 $width = $item[0]; 32 32 $height = $item[1]; 33 33 34 34 $spacex = 32; 35 35 $spacey = 68; 36 36 $halfx = $spacex / 2; 37 37 $halfy = $spacey / 2; 38 // Načtení pomocných obrázků 38 // Načtení pomocných obrázků 39 39 $im_comp = imagecreatefrompng(dirname(__FILE__).'/images/comp.png'); 40 40 $im_dev = imagecreatefrompng(dirname(__FILE__).'/images/device.png'); … … 47 47 $blue = imagecolorallocate($im, 100, 100, 255); 48 48 $gray = imagecolorallocate($im, 160, 160, 160); 49 49 50 50 //$DbResult = $Database->query("SELECT * FROM hosts, NetworkTopology WHERE host = id AND used=1"); 51 51 $DbResult = $this->Database->query('SELECT NetworkTopology.*, NetworkTopology.Host AS Id, '. … … 98 98 } 99 99 } 100 100 101 101 // === Sestavení výsledného souboru ============================================ 102 102 if($debug == 0) 103 103 { 104 104 Header("Content-type: image/png"); 105 Header("Cache-Control: no-cache"); 105 Header("Cache-Control: no-cache"); // Dynamický graf, nekešovat 106 106 imagepng($im); 107 107 imagedestroy($im); … … 111 111 return(''); 112 112 } 113 113 114 114 function ShowOverview() 115 115 { … … 142 142 $this->Dependencies = array('Network'); 143 143 } 144 144 145 145 function DoInstall() 146 146 { 147 147 } 148 148 149 149 function DoUnInstall() 150 150 {
Note:
See TracChangeset
for help on using the changeset viewer.