public function compile($file, $mode = 1) { switch ($mode) { case 1: return eaccelerator_encode($file); break; case 2: return eaccelerator_dasm_file($file); break; default: return eaccelerator_encode($file); } }
<div class="head1"><span class="head1_item">eAccelerator control panel</span></div> <div class="head2"> <?php $items = array(0 => 'Status', 1 => 'Script Cache'); foreach ($items as $i => $item) { echo '<span class="menuitem' . ($sec == $i ? '_sel' : '') . '" onmouseover="menusel(this)" onmouseout="menusel(this)" onclick="gosec(' . $i . ')">' . ($sec != $i ? '<a href="control.php?sec=' . $i . '">' . $item . '</a>' : $item) . '</span>'; } ?> </div> <div class="center"> <?php if (!isset($_GET['file']) || !is_file($_GET['file'])) { die('File argument not given!'); } $file = $_GET['file']; $asm = eaccelerator_dasm_file($file); if ($asm == null) { die('File not found!'); } require_once 'PHP_Highlight.php'; $h = new PHP_Highlight(); $h->loadFile($_GET['file']); $source = $h->toArray(); /* what do we need to do ? */ if (!isset($_GET['show'])) { $show = ''; } else { $show = $_GET['show']; } print_layout(); switch ($show) {