コード例 #1
0
 public static function init()
 {
     self::$cacheDir = '../../../' . Config::$cache_folder . '/images';
     self::$documentRoot = '../../..';
     // This must be the last line of this function
     parent::init();
 }
コード例 #2
0
 public static function init()
 {
     if (isset($_GET['users'])) {
         self::$documentRoot = '../../../../files/uploads/users';
     }
     // This must be the last line of this function
     parent::init();
 }
コード例 #3
0
 /**
  * @return void
  */
 protected function setUp()
 {
     $this->slir = new SLIR();
     SLIRConfig::$defaultImagePath = null;
     SLIRConfig::$forceQueryString = false;
     SLIRConfig::$enableErrorImages = false;
     SLIRConfig::$defaultCropper = SLIR::CROP_CLASS_CENTERED;
     SLIRConfig::$copyEXIF = false;
     SLIRConfig::$maxMemoryToAllocate = -1;
     // Try to fix documentRoot for CLI
     SLIRConfig::$documentRoot = realpath(__DIR__ . '/../../');
 }