0
我从服务器收到以下错误:CKEditor的:致命错误:要求()[function.require]:未能开口要求 '__DIR __ /郎/ en.php')
Fatal error: require() [function.require]: Failed opening required '__DIR__/lang/en.php' (include_path='.:/usr/local/php5/lib/php') in /home/content/38/8264638/html/console/assets/ckeditor/plugins/imageuploader/imgbrowser.php on line 16
在我的我的CKEditor整合imageuploader和工作在我的本地服务器,但它不是在托管server.its工作并称imagebrowser.php文件中的错误以下是imagebrowser.php..please代码帮助我..
<?php
session_start();
$link = "http://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]";
$root = "http://$_SERVER[HTTP_HOST]";
// checking lang value
if(isset($_COOKIE['sy_lang'])) {
$load_lang_code = $_COOKIE['sy_lang'];
} else {
$load_lang_code = "en";
}
// including lang files
switch ($load_lang_code) {
case "en":
require(__DIR__ . '/lang/en.php');
break;
case "pl":
require(__DIR__ . '/lang/pl.php');
break;
}
// Including the plugin config file, don't delete the following row!
require(__DIR__ . '/pluginconfig.php');
// Including the functions file, don't delete the following row!
require(__DIR__ . '/function.php');
// Including the check_permission file, don't delete the following row!
require(__DIR__ . '/check_permission.php');
$_SESSION["username"] = "disabled_pw";
?>
更新PHP版本是不是真的简单的任务:) 它需要大量的effofrt –
如何要求的(__ DIR__ '/lang/en.php');替换为dirname(__ FILE__).. @ @黑暗的Absol(如何在我的代码中实现) –
@AlexandrKapustin当然,但从长远来看这是最好的解决方案。例如,如果我们可以说服每个人升级到PHP7,那么我们不会再有人抱怨说'mysql_fetch_assoc'希望参数1是资源,布尔值给定。 –