checkACL($this->acl)) { $this->correct_acl = true; } else { $this->correct_acl = false; } } private function getFilters() { $system = System::getInstance(); $this->id = (int)$system->getRequest('id', 0); } public function show() { $this->getFilters(); $this->visualmap = db_get_row('tlayout', 'id', $this->id); if (empty($this->visualmap)) { $this->show_fail_acl(); } $this->checkVisualmapACL($this->visualmap['id_group']); if (!$this->correct_acl) { $this->show_fail_acl(); } $this->show_visualmap(); } private function show_fail_acl() { $error['type'] = 'onStart'; $error['title_text'] = __('You don\'t have access to this page'); $error['content_text'] = System::getDefaultACLFailText(); if (class_exists("HomeEnterprise")) $home = new HomeEnterprise(); else $home = new Home(); $home->show($error); } public function ajax($parameter2 = false) { $system = System::getInstance(); $this->checkVisualmapACL($this->visualmap['id_group']); if (!$this->correct_acl) { $this->show_fail_acl(); } else { switch ($parameter2) { case 'render_map': $map_id = $system->getRequest('map_id', '0'); $width = $system->getRequest('width', '400'); $height = $system->getRequest('height', '400'); visual_map_print_visual_map($map_id, false, true, $width, $height); exit; } } } private function show_visualmap() { $ui = Ui::getInstance(); $system = System::getInstance(); $ui->createPage(); $ui->createDefaultHeader( sprintf("%s", $this->visualmap['name']), $ui->createHeaderButton( array('icon' => 'back', 'pos' => 'left', 'text' => __('Back'), 'href' => 'index.php?page=visualmaps'))); $ui->showFooter(false); $ui->beginContent(); ob_start(); $rendered_map = '