setup switch in config

This commit is contained in:
overflowerror 2014-08-17 18:16:46 +02:00
parent b6b93253c8
commit 3512de7bc1
2 changed files with 4 additions and 3 deletions

View file

@ -1,5 +1,6 @@
<?php <?php
define("BETA", true); define("BETA", true);
define("ENABLE_SETUP", false);
define("LOG_FILE", "/var/www/websites/webcli/internal.log"); define("LOG_FILE", "/var/www/websites/webcli/internal.log");

View file

@ -1,10 +1,10 @@
<?php <?php
//die(); // comment for setup
require_once("mysqlConnect.php"); require_once("mysqlConnect.php");
require_once("config.php"); require_once("config.php");
if (!ENABLE_SETUP)
die("Setup disabled. Take a look at ./config.php");
if ($db->query("SET SESSION sql_mode='NO_AUTO_VALUE_ON_ZERO'") !== true) if ($db->query("SET SESSION sql_mode='NO_AUTO_VALUE_ON_ZERO'") !== true)
echo "seting mode <span style=\"color: red\">failed</span>.<br />"; echo "seting mode <span style=\"color: red\">failed</span>.<br />";
else else