When i try to use epesi with ipad (mobile.php), i get all the time error 500. I asked our hosting service (we have windows server in use), the told me that its something to do with local dir. (error our service provider got was: Detection of epesi directory failed. Please define EPESI_DIR variable in config.php)
I opened config.php:
//other
@define('SYSTEM_TIMEZONE',date_default_timezone_get());
date_default_timezone_set(SYSTEM_TIMEZONE);
$local_dir = dirname(dirname(str_replace('\\','/',__FILE__)));
define('EPESI_LOCAL_DIR',$local_dir);
$script_filename = str_replace('\\','/',$_SERVER['SCRIPT_FILENAME']);
$detection_failed = strcmp($local_dir,substr($script_filename,0,strlen($local_dir)));
if(!defined('EPESI_DIR')) {
if(!$detection_failed) {
$file_url = substr($script_filename,strlen($local_dir));
$dir_url = substr($_SERVER['SCRIPT_NAME'],0,strlen($_SERVER['SCRIPT_NAME'])-strlen($file_url));
$dir = trim($dir_url,'/');
$epesi_dir = '/'.$dir.($dir?'/':'');
define('EPESI_DIR',$epesi_dir);
} elseif(PHP_SAPI=='cli') {
define("EPESI_DIR","");
} else {
trigger_error('Detection of epesi directory failed. Please define EPESI_DIR variable in config.php',E_USER_ERROR);
}
How should i change it to not get error anymore ? With use on pc, the normal site works ok most of the time, so its mobiledevice use thats problem.