Changeset 19805 for branches/version-2_5-dev/data/class/SC_Initial.php
- Timestamp:
- 2010/12/31 23:23:49 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/version-2_5-dev/data/class/SC_Initial.php
r19803 r19805 75 75 if (defined('ECCUBE_INSTALL')) { 76 76 define('MOBILE_DIR', 'mobile/'); 77 define('MOBILE_HTML_ FILE_PATH', HTML_FILE_PATH. MOBILE_DIR);77 define('MOBILE_HTML_REALDIR', HTML_REALDIR . MOBILE_DIR); 78 78 define('MOBILE_HTTP_URL', HTTP_URL . MOBILE_DIR); 79 79 define('MOBILE_HTTPS_URL', HTTPS_URL . MOBILE_DIR); … … 81 81 82 82 define('SMARTPHONE_DIR', 'sphone/'); 83 define('SMARTPHONE_HTML_ FILE_PATH', HTML_FILE_PATH. SMARTPHONE_DIR);83 define('SMARTPHONE_HTML_REALDIR', HTML_REALDIR . SMARTPHONE_DIR); 84 84 define('SMARTPHONE_HTTP_URL', HTTP_URL . SMARTPHONE_DIR); 85 85 define('SMARTPHONE_HTTPS_URL', HTTPS_URL . SMARTPHONE_DIR); … … 190 190 $errorMessage = "<div style='color: #F00; font-weight: bold; " 191 191 . "background-color: #FEB; text-align: center'>" 192 . CACHE_ FILE_PATH192 . CACHE_REALDIR 193 193 . " にユーザ書込み権限(777等)を付与して下さい。</div>"; 194 194 195 195 // 定数を設定 196 if (is_file(CACHE_ FILE_PATH. "mtb_constants.php")) {197 require_once(CACHE_ FILE_PATH. "mtb_constants.php");196 if (is_file(CACHE_REALDIR . "mtb_constants.php")) { 197 require_once(CACHE_REALDIR . "mtb_constants.php"); 198 198 199 199 // キャッシュが無ければ, 初期データからコピー 200 } elseif (is_file(CACHE_ FILE_PATH. "../mtb_constants_init.php")) {201 202 $mtb_constants = file_get_contents(CACHE_ FILE_PATH. "../mtb_constants_init.php");203 if (is_writable(CACHE_ FILE_PATH)) {204 $handle = fopen(CACHE_ FILE_PATH. "mtb_constants.php", "w");200 } elseif (is_file(CACHE_REALDIR . "../mtb_constants_init.php")) { 201 202 $mtb_constants = file_get_contents(CACHE_REALDIR . "../mtb_constants_init.php"); 203 if (is_writable(CACHE_REALDIR)) { 204 $handle = fopen(CACHE_REALDIR . "mtb_constants.php", "w"); 205 205 if (!$handle) { 206 206 die($errorMessage); … … 211 211 fclose($handle); 212 212 213 require_once(CACHE_ FILE_PATH. "mtb_constants.php");213 require_once(CACHE_REALDIR . "mtb_constants.php"); 214 214 } else { 215 215 die($errorMessage); 216 216 } 217 217 } else { 218 die(CACHE_ FILE_PATH. "../mtb_constants_init.php が存在しません");218 die(CACHE_REALDIR . "../mtb_constants_init.php が存在しません"); 219 219 } 220 220 } … … 229 229 */ 230 230 function createCacheDir() { 231 if (defined("HTML_ FILE_PATH")) {231 if (defined("HTML_REALDIR")) { 232 232 umask(0); 233 233 if (!file_exists(COMPILE_DIR)) { … … 235 235 } 236 236 237 if (!file_exists(MOBILE_COMPILE_ FILE_PATH)) {238 mkdir(MOBILE_COMPILE_ FILE_PATH);239 } 240 241 if (!file_exists(SMARTPHONE_COMPILE_ FILE_PATH)) {242 mkdir(SMARTPHONE_COMPILE_ FILE_PATH);243 } 244 245 if (!file_exists(COMPILE_ADMIN_ FILE_PATH)) {246 mkdir(COMPILE_ADMIN_ FILE_PATH);237 if (!file_exists(MOBILE_COMPILE_REALDIR)) { 238 mkdir(MOBILE_COMPILE_REALDIR); 239 } 240 241 if (!file_exists(SMARTPHONE_COMPILE_REALDIR)) { 242 mkdir(SMARTPHONE_COMPILE_REALDIR); 243 } 244 245 if (!file_exists(COMPILE_ADMIN_REALDIR)) { 246 mkdir(COMPILE_ADMIN_REALDIR); 247 247 } 248 248 }
Note: See TracChangeset
for help on using the changeset viewer.
