<?php
/*
Copyright © 2009-2012 Commentics Development Team [commentics.org]
License: GNU General Public License v3.0
		 http://www.commentics.org/license/

This file is part of Commentics.

Commentics is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

Commentics is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with Commentics. If not, see <http://www.gnu.org/licenses/>.

Text to help preserve UTF-8 file encoding: 汉语漢語.
*/

if (isset($_POST['submit'])) {
	if ($_POST['action'] == 'install') {
		header("Location: " . "http://" . $_SERVER['HTTP_HOST'] . dirname($_SERVER['PHP_SELF']) . "/install_1.php");
		die();
	} else {
		header("Location: " . "http://" . $_SERVER['HTTP_HOST'] . dirname($_SERVER['PHP_SELF']) . "/upgrade_1.php");
		die();
	}
}
?>
<html>
<head>
<title>Installer</title>
<meta name="robots" content="noindex"/>
<link rel="stylesheet" type="text/css" href="css/stylesheet.css"/>
</head>
<body>

<img src="../images/commentics/logo.png" class="logo" title="Commentics" alt="Commentics"/>

<br />

Would you like to install or upgrade the programme?

<p />

<form name="installer" id="installer" action="<?php echo htmlentities($_SERVER['PHP_SELF']); ?>" method="post">

<input type="radio" name="action" value="install" checked="checked"/> Install
<br />
<input type="radio" name="action" value="upgrade" /> Upgrade

<p />

<input type="submit" name="submit" value="Continue"/>

</form>

</body>
</html>