mirror of
https://github.com/Oreolek/ifhub.club.git
synced 2024-05-20 17:58:24 +03:00
fix проблемы с включенным у некоторых хостингов в include_path пути до Zend
This commit is contained in:
parent
66848b9577
commit
4f5d90a0ad
|
@ -9,7 +9,7 @@
|
|||
*
|
||||
* $Id$
|
||||
*/
|
||||
require_once "Zend/Cache/Backend/Memcached.php";
|
||||
require_once LS_DKCACHE_PATH."Zend/Cache/Backend/Memcached.php";
|
||||
|
||||
class Dklab_Cache_Backend_MemcachedMultiload extends Zend_Cache_Backend_Memcached
|
||||
{
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
*
|
||||
* $Id$
|
||||
*/
|
||||
require_once "Zend/Cache/Backend/Interface.php";
|
||||
require_once LS_DKCACHE_PATH."Zend/Cache/Backend/Interface.php";
|
||||
|
||||
class Dklab_Cache_Backend_Profiler implements Zend_Cache_Backend_Interface
|
||||
{
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
*
|
||||
* $Id$
|
||||
*/
|
||||
require_once "Zend/Cache/Backend/Interface.php";
|
||||
require_once LS_DKCACHE_PATH."Zend/Cache/Backend/Interface.php";
|
||||
|
||||
class Dklab_Cache_Backend_TagEmuWrapper implements Zend_Cache_Backend_Interface
|
||||
{
|
||||
|
|
10
engine/lib/external/DklabCache/Zend/Cache.php
vendored
10
engine/lib/external/DklabCache/Zend/Cache.php
vendored
|
@ -87,12 +87,12 @@ abstract class Zend_Cache
|
|||
$frontendClass = 'Zend_Cache_' . ($frontend != 'Core' ? 'Frontend_' : '') . $frontend;
|
||||
// For perfs reasons, we do not use the Zend_Loader::loadClass() method
|
||||
// (security controls are explicit)
|
||||
require_once str_replace('_', DIRECTORY_SEPARATOR, $frontendClass) . '.php';
|
||||
require_once LS_DKCACHE_PATH.str_replace('_', DIRECTORY_SEPARATOR, $frontendClass) . '.php';
|
||||
} else {
|
||||
// we use a custom frontend
|
||||
$frontendClass = 'Zend_Cache_Frontend_' . $frontend;
|
||||
// To avoid security problems in this case, we use Zend_Loader to load the custom class
|
||||
require_once 'Zend/Loader.php';
|
||||
require_once LS_DKCACHE_PATH.'Zend/Loader.php';
|
||||
$file = str_replace('_', DIRECTORY_SEPARATOR, $frontendClass) . '.php';
|
||||
if (!(Zend_Loader::isReadable($file))) {
|
||||
self::throwException("file $file not found in include_path");
|
||||
|
@ -106,12 +106,12 @@ abstract class Zend_Cache
|
|||
$backendClass = 'Zend_Cache_Backend_' . $backend;
|
||||
// For perfs reasons, we do not use the Zend_Loader::loadClass() method
|
||||
// (security controls are explicit)
|
||||
require_once str_replace('_', DIRECTORY_SEPARATOR, $backendClass) . '.php';
|
||||
require_once LS_DKCACHE_PATH.str_replace('_', DIRECTORY_SEPARATOR, $backendClass) . '.php';
|
||||
} else {
|
||||
// we use a custom backend
|
||||
$backendClass = 'Zend_Cache_Backend_' . $backend;
|
||||
// To avoid security problems in this case, we use Zend_Loader to load the custom class
|
||||
require_once 'Zend/Loader.php';
|
||||
require_once LS_DKCACHE_PATH.'Zend/Loader.php';
|
||||
$file = str_replace('_', DIRECTORY_SEPARATOR, $backendClass) . '.php';
|
||||
if (!(Zend_Loader::isReadable($file))) {
|
||||
self::throwException("file $file not found in include_path");
|
||||
|
@ -137,7 +137,7 @@ abstract class Zend_Cache
|
|||
public static function throwException($msg)
|
||||
{
|
||||
// For perfs reasons, we use this dynamic inclusion
|
||||
require_once 'Zend/Cache/Exception.php';
|
||||
require_once LS_DKCACHE_PATH.'Zend/Cache/Exception.php';
|
||||
throw new Zend_Cache_Exception($msg);
|
||||
}
|
||||
|
||||
|
|
|
@ -188,7 +188,7 @@ class Zend_Cache_Backend
|
|||
* @see Zend_Loader
|
||||
* @see Zend_Log
|
||||
*/
|
||||
require_once 'Zend/Loader.php';
|
||||
require_once LS_DKCACHE_PATH.'Zend/Loader.php';
|
||||
Zend_Loader::loadClass('Zend_Log');
|
||||
} catch (Zend_Exception $e) {
|
||||
Zend_Cache::throwException('Logging feature is enabled but the Zend_Log class is not available');
|
||||
|
|
|
@ -23,12 +23,12 @@
|
|||
/**
|
||||
* @see Zend_Cache_Backend_Interface
|
||||
*/
|
||||
require_once 'Zend/Cache/Backend/Interface.php';
|
||||
require_once LS_DKCACHE_PATH.'Zend/Cache/Backend/Interface.php';
|
||||
|
||||
/**
|
||||
* @see Zend_Cache_Backend
|
||||
*/
|
||||
require_once 'Zend/Cache/Backend.php';
|
||||
require_once LS_DKCACHE_PATH.'Zend/Cache/Backend.php';
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
@ -23,12 +23,12 @@
|
|||
/**
|
||||
* @see Zend_Cache_Backend_Interface
|
||||
*/
|
||||
require_once 'Zend/Cache/Backend/Interface.php';
|
||||
require_once LS_DKCACHE_PATH.'Zend/Cache/Backend/Interface.php';
|
||||
|
||||
/**
|
||||
* @see Zend_Cache_Backend
|
||||
*/
|
||||
require_once 'Zend/Cache/Backend.php';
|
||||
require_once LS_DKCACHE_PATH.'Zend/Cache/Backend.php';
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
/**
|
||||
* @see Zend_Exception
|
||||
*/
|
||||
require_once 'Zend/Exception.php';
|
||||
require_once LS_DKCACHE_PATH.'Zend/Exception.php';
|
||||
|
||||
/**
|
||||
* @package Zend_Cache
|
||||
|
|
5
engine/lib/external/DklabCache/config.php
vendored
5
engine/lib/external/DklabCache/config.php
vendored
|
@ -1,5 +1,4 @@
|
|||
<?php
|
||||
if (!defined("PATH_SEPARATOR"))
|
||||
define("PATH_SEPARATOR", getenv("COMSPEC")? ";" : ":");
|
||||
ini_set("include_path", ini_get("include_path").PATH_SEPARATOR.dirname(__FILE__));
|
||||
if (!defined("LS_DKCACHE_PATH"))
|
||||
define("LS_DKCACHE_PATH", dirname(__FILE__).'/');
|
||||
?>
|
12
engine/modules/cache/Cache.class.php
vendored
12
engine/modules/cache/Cache.class.php
vendored
|
@ -16,10 +16,10 @@
|
|||
*/
|
||||
|
||||
require_once(Config::Get('path.root.engine').'/lib/external/DklabCache/config.php');
|
||||
require_once('Zend/Cache.php');
|
||||
require_once('Cache/Backend/MemcachedMultiload.php');
|
||||
require_once('Cache/Backend/TagEmuWrapper.php');
|
||||
require_once('Cache/Backend/Profiler.php');
|
||||
require_once(LS_DKCACHE_PATH.'Zend/Cache.php');
|
||||
require_once(LS_DKCACHE_PATH.'Cache/Backend/MemcachedMultiload.php');
|
||||
require_once(LS_DKCACHE_PATH.'Cache/Backend/TagEmuWrapper.php');
|
||||
require_once(LS_DKCACHE_PATH.'Cache/Backend/Profiler.php');
|
||||
|
||||
/**
|
||||
* Типы кеширования: file и memory
|
||||
|
@ -63,7 +63,7 @@ class LsCache extends Module {
|
|||
return false;
|
||||
}
|
||||
if ($this->sCacheType==SYS_CACHE_TYPE_FILE) {
|
||||
require_once('Zend/Cache/Backend/File.php');
|
||||
require_once(LS_DKCACHE_PATH.'Zend/Cache/Backend/File.php');
|
||||
$oCahe = new Zend_Cache_Backend_File(
|
||||
array(
|
||||
'cache_dir' => Config::Get('sys.cache.dir'),
|
||||
|
@ -76,7 +76,7 @@ class LsCache extends Module {
|
|||
);
|
||||
$this->oBackendCache = new Dklab_Cache_Backend_Profiler($oCahe,array($this,'CalcStats'));
|
||||
} elseif ($this->sCacheType==SYS_CACHE_TYPE_MEMORY) {
|
||||
require_once('Zend/Cache/Backend/Memcached.php');
|
||||
require_once(LS_DKCACHE_PATH.'Zend/Cache/Backend/Memcached.php');
|
||||
$aConfigMem=Config::Get('memcache');
|
||||
|
||||
$oCahe = new Dklab_Cache_Backend_MemcachedMultiload($aConfigMem);
|
||||
|
|
Loading…
Reference in a new issue