- fixed rewriteRule if aowow is not in your root dir

- use https if available, added a config value to enforce it if nessecary
- NPC:
  * fixed currency icons when displaying extendedCost for vendor
  * display conditions column only if we actually have conditions set
This commit is contained in:
Sarjuuk
2014-09-09 20:40:12 +02:00
parent a5ce57ddf8
commit 2e18bf0d3e
4 changed files with 16 additions and 7 deletions

View File

@@ -70,8 +70,13 @@ $sets = DB::Aowow()->select('SELECT `key` AS ARRAY_KEY, intValue as i, strValue
foreach ($sets as $k => $v)
define('CFG_'.strtoupper($k), $v['s'] ?: intVal($v['i']));
define('STATIC_URL', substr('http://'.$_SERVER['SERVER_NAME'].strtr($_SERVER['SCRIPT_NAME'], ['index.php' => '']), 0, -1).'/static'); // points js to images & scripts (change here if you want to use a separate subdomain)
define('HOST_URL', substr('http://'.$_SERVER['SERVER_NAME'].strtr($_SERVER['SCRIPT_NAME'], ['index.php' => '']), 0, -1)); // points js to executable files
$protocoll = 'http://';
if ((!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] != 'off') || CFG_FORCE_SSL)
$protocoll = 'https://';
define('STATIC_URL', substr($protocoll.$_SERVER['SERVER_NAME'].strtr($_SERVER['SCRIPT_NAME'], ['index.php' => '']), 0, -1).'/static'); // points js to images & scripts (change here if you want to use a separate subdomain)
define('HOST_URL', substr($protocoll.$_SERVER['SERVER_NAME'].strtr($_SERVER['SCRIPT_NAME'], ['index.php' => '']), 0, -1)); // points js to executable files
$e = CFG_DEBUG ? (E_ALL & ~(E_DEPRECATED | E_USER_DEPRECATED | E_STRICT)) : 0;
error_reporting($e);