警告:require_once(C:/wamp/www/saleshub/system/startup.php(:失败打开流:没有这样的文件或目录C:''xampp''htdocs''saleshub''index.php 在第 17 行
致命错误:require_once((:需要打开失败"C:/wamp/www/saleshub/system/startup.php"(include_path='.;C:''xampp''php''PEAR'( inC:''xampp''htdocs''saleshub''index.php 在第 17 行
索引.php
<?php
// Version
define('VERSION', '2.0.2.0');
// Configuration
if (is_file('config.php')) {
require_once('config.php');
}
// Install
if (!defined('DIR_APPLICATION')) {
header('Location: install/index.php');
exit;
}
// Startup
require_once(DIR_SYSTEM . 'startup.php');
// Registry
$registry = new Registry();
// Loader
$loader = new Loader($registry);
$registry->set('load', $loader);
startup.php coding
<?php
// Error Reporting
error_reporting(E_ALL);
// Check Version
if (version_compare(phpversion(), '5.3.0', '<') == true) {
exit('PHP5.3+ Required');
}
if (!ini_get('date.timezone')) {
date_default_timezone_set('UTC');
}
// Windows IIS Compatibility
if (!isset($_SERVER['DOCUMENT_ROOT'])) {
if (isset($_SERVER['SCRIPT_FILENAME'])) {
$_SERVER['DOCUMENT_ROOT'] = str_replace('''', '/', substr($_SERVER['SCRIPT_FILENAME'], 0, 0 - strlen($_SERVER['PHP_SELF'])));
}
}
我认为你的变量是错误的。我只是从你的如果条件假设。你需要DIR_APPLICATION
而不是DIR_SYSTEM
.所以你的代码将是:
require_once(DIR_APPLICATION. 'startup.php');