无法读取目录内的文件

时间:2019-05-16 20:47:30

标签: php

我在严格模式下出现错误?我看了目录的路径,这是正确的。我尝试将所有文​​件都放在777中,但存在相同的问题。

似乎未读到此行:

@dir(Core::getConfig('dir_root', 'Shop') . 'includes/modules/security_check/')

产生的错误

    string(8) "extended" 
    Warning: include(/........./config_file_catalog.php): failed to open stream: No such file or directory in /......./SecurityCheck.php on line 75

    Warning: include(): Failed opening '/......./config_file_catalog.php' for inclusion 

(include_path='.:/usr/share/php') in /....../SecurityCheck.php on line 75

代码:

  if ($secdir = @dir(Core::getConfig('dir_root', 'Shop') . 'includes/modules/security_check/')) {
    while ($file = $secdir->read()) {
      if (!is_file(Core::getConfig('dir_root') . 'includes/modules/security_check/' . $file)) {
        if (substr($file, strrpos($file, '.')) == $file_extension) {
          $secmodules_array[] = $file;
        }
      }
    }
    sort($secmodules_array);
    $secdir->close();
  }

0 个答案:

没有答案