<?php
define('V3_ROOT', $_SERVER['DOCUMENT_ROOT'] . '/v3');
define('V3_INC', V3_ROOT . '/includes');
require_once(V3_ROOT . '/includes/v3.inc');
$file = 'index.php';
if(isset($_GET['file'])) {
$file = basename(urldecode($_GET['file']));
}
if(!file_exists($file)) {
if(file_exists(V3_INC . "/$file"))
$file = V3_INC . "/$file";
else
die("$file not found!");
}
$hl = v3_factory::new_instance('highlighter', $file, true);
print $hl->highlight();
?>