<title><?php echo lang('phpMinAdmin') . " - $title"; ?></title>
<link rel="shortcut icon" type="image/x-icon" href="favicon.ico" />
<link rel="stylesheet" type="text/css" href="default.css" />
-<?php if ($_SESSION["highlight"] == "jush") { ?>
+<?php if ($_COOKIE["highlight"] == "jush") { ?>
<style type="text/css">@import url(http://jush.info/jush.css);</style>
<script type="text/javascript" src="http://jush.info/jush.js" defer="defer"></script>
<script type="text/javascript">window.onload = function () { jush.highlight_tag('pre'); }</script>
<?php
if (isset($_POST["query"])) {
- $_SESSION["highlight"] = $_POST["highlight"];
+ setcookie("highlight", $_POST["highlight"], strtotime("+1 month"));
+ $_COOKIE["highlight"] = $_POST["highlight"];
}
page_header(lang('SQL command'));
<input type="hidden" name="token" value="<?php echo $token; ?>" />
<input type="submit" value="<?php echo lang('Execute'); ?>" />
<script type="text/javascript">
-document.write('<label for="highlight"><input type="checkbox" name="highlight" id="highlight" value="jush"<?php echo ($_SESSION["highlight"] == "jush" ? ' checked="checked"' : ''); ?> /><?php echo addcslashes(lang('Syntax highlighting'), "\r\n'\\"); ?></label>');
+document.write('<label for="highlight"><input type="checkbox" name="highlight" id="highlight" value="jush"<?php echo ($_COOKIE["highlight"] == "jush" ? ' checked="checked"' : ''); ?> /><?php echo addcslashes(lang('Syntax highlighting'), "\r\n'\\"); ?></label>');
</script>
</p>
</form>