美文网首页
OneIndex重建缓存页面报错

OneIndex重建缓存页面报错

作者: 徐州小虫 | 来源:发表于2020-03-22 15:43 被阅读0次

    OneIndex重建缓存页面可能出现以下报错信息:

    Warning: file_exists(): open_basedir restriction in effect. File(/bin/php) is not within the allowed path(s): (/****/:/tmp/:/proc/) in /****/view/admin/cache.php on line 12
    

    修改方式为,打开view/admin/cache.php页面,注释掉以下代码:

    /****注释开始(此文件的第4行)*******
      $paths = explode(PATH_SEPARATOR, getenv('PATH'));
      foreach ($paths as $path) {
        if (strstr($path, 'php.exe') && isset($_SERVER["WINDIR"]) && file_exists($path) && is_file($path)) {
            return $path;
        }
        else {
            $php_executable = $path . DIRECTORY_SEPARATOR . "php" . (isset($_SERVER["WINDIR"]) ? ".exe" : "");
            if (file_exists($php_executable) && is_file($php_executable)) {
               return $php_executable;
            }
        }
      }
      *********注释结束(此文件的第15行)******/
    

    相关文章

      网友评论

          本文标题:OneIndex重建缓存页面报错

          本文链接:https://www.haomeiwen.com/subject/cflvyhtx.html