Skip to content
Snippets Groups Projects
Commit b1f3ffde authored by jgaimard's avatar jgaimard
Browse files

Compatibilité windows

parent 795f2b35
Branches
Tags
5 merge requests!258Dev/13872 Orphee Allow Hold Available Items,!63Rf13038,!56Rf13038 Front,!47Hotline 6.40,!37Hotline#12794 Analyse Fichiers Cosmo
......@@ -29,7 +29,12 @@ class CosmoPaths {
while ((count($parts)>0) && (end($parts) !== self::COSMO_DIR_NAME))
array_pop($parts);
array_pop($parts);
return '/' . implode('/', $parts) . '/';
return ($this->isWindowsPath() ? '' : '/') . implode('/', $parts) . '/';
}
public function isWindowsPath() {
return strtoupper(substr(PHP_OS, 0, 3)) === 'WIN';
}
......
......@@ -16,7 +16,8 @@
* GNU AFFERO GENERAL PUBLIC LICENSE for more details.
*
* You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE
* along with AFI-OPAC 2.0; if not, write to the Free Software
* along with AFI-OPAC 2.0; if not, write to Zend_Loader::registerAutoload();
the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
......@@ -29,21 +30,21 @@ if (!defined('LANG_DIR'))
define('LANG_DIR', OPAC_PATH.'/library/translation/');
set_include_path(get_include_path()
. PATH_SEPARATOR . OPAC_PATH . '/library'
. PATH_SEPARATOR . OPAC_PATH . '/library/storm/src');
. PATH_SEPARATOR . OPAC_PATH . 'library'
. PATH_SEPARATOR . OPAC_PATH . 'library/storm/src');
// Includes de base
include_once "fonctions/array.php";
include_once OPAC_PATH."/local.php";
if (!defined('ZEND_FRAMEWORK_PATH'))
define ('ZEND_FRAMEWORK_PATH', PATH_SEPARATOR . OPAC_PATH . '/library/storm/zf/library');
define ('ZEND_FRAMEWORK_PATH', PATH_SEPARATOR . OPAC_PATH . 'library/storm/zf/library');
set_include_path(ZEND_FRAMEWORK_PATH . PATH_SEPARATOR . get_include_path());
require_once "Zend/Loader.php";
require_once "startup.php";
require_once 'Zend/Loader.php';
Zend_Loader::registerAutoload();
require_once "startup.php";
$cfg_file = (new CosmoPaths())->getBokehConfigPath();
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment