#0 [2]ErrorException in File.php line 33

mkdir(): File exists

  1. * @param string $content 缓存的内容
  2. * @return void
  3. */
  4. public function write(string $cacheFile, string $content): void
  5. {
  6. // 检测模板目录
  7. $dir = dirname($cacheFile);
  8. if (!is_dir($dir)) {
  9. mkdir($dir, 0755, true);
  10. }
  11. // 生成模板缓存文件
  12. if (false === file_put_contents($cacheFile, $content)) {
  13. throw new Exception('cache write error:' . $cacheFile, 11602);
  14. }
  15. }
  16. /**

Call Stack

  1. in File.php line 33
  2. at Error->appError()
  3. at mkdir() in File.php line 33
  4. at File->write() in Template.php line 429
  5. at Template->compiler() in Template.php line 243
  6. at Template->fetch() in Think.php line 149
  7. at Think->fetch() in View.php line 90
  8. at View->think\{closure}() in View.php line 126
  9. at View->getContent() in View.php line 91
  10. at View->fetch() in Index.php line 225
  11. at Index->show()
  12. at ReflectionMethod->invokeArgs() in Container.php line 344
  13. at Container->invokeReflectMethod() in Controller.php line 110
  14. at Controller->think\route\dispatch\{closure}() in Pipeline.php line 59
  15. at Pipeline->think\{closure}() in Pipeline.php line 66
  16. at Pipeline->then() in Controller.php line 113
  17. at Controller->exec() in Dispatch.php line 90
  18. at Dispatch->run() in Route.php line 785
  19. at Route->think\{closure}() in Pipeline.php line 59
  20. at Pipeline->think\{closure}() in Pipeline.php line 66
  21. at Pipeline->then() in Route.php line 786
  22. at Route->dispatch() in Http.php line 216
  23. at Http->dispatchToRoute() in Http.php line 206
  24. at Http->think\{closure}() in Pipeline.php line 59
  25. at Pipeline->think\{closure}() in MultiApp.php line 71
  26. at MultiApp->think\app\{closure}() in Pipeline.php line 59
  27. at Pipeline->think\{closure}() in HtmlCache.php line 26
  28. at HtmlCache->handle()
  29. at call_user_func() in Middleware.php line 142
  30. at Middleware->think\{closure}() in Pipeline.php line 85
  31. at Pipeline->think\{closure}() in LoadLangPack.php line 98
  32. at LoadLangPack->handle()
  33. at call_user_func() in Middleware.php line 142
  34. at Middleware->think\{closure}() in Pipeline.php line 85
  35. at Pipeline->think\{closure}() in Pipeline.php line 66
  36. at Pipeline->then() in MultiApp.php line 72
  37. at MultiApp->handle()
  38. at call_user_func() in Middleware.php line 142
  39. at Middleware->think\{closure}() in Pipeline.php line 85
  40. at Pipeline->think\{closure}() in SessionInit.php line 67
  41. at SessionInit->handle()
  42. at call_user_func() in Middleware.php line 142
  43. at Middleware->think\{closure}() in Pipeline.php line 85
  44. at Pipeline->think\{closure}() in Pipeline.php line 66
  45. at Pipeline->then() in Http.php line 207
  46. at Http->runWithRequest() in Http.php line 170
  47. at Http->run() in index.php line 29

Environment Variables

GET Dataempty
POST Dataempty
Filesempty
Cookiesempty
Sessionempty
Server/Request Data
USER www
HOME /home/www
HTTP_X_ALICDN_DA_VIA 8.25.82.231,42.96.223.32
HTTP_ALI_SWIFT_RANGE_CACHE on
HTTP_ALI_CDN_ADAPTIVE_PORTS 80,443
HTTP_ALI_SWIFT_ORIGIN_PORT 443
HTTP_ALI_SWIFT_ORIGIN_SCHEME https
HTTP_ALI_CDN_APPVIEW_NAME cdn-tengine
HTTP_ACCEPT_ENCODING gzip, br, zstd, deflate
HTTP_USER_AGENT Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
HTTP_ACCEPT */*
HTTP_ALI_SWIFT_FORCE_TTL_CODE 400=0
HTTP_ALI_SWIFT_FORCE_CACHE_CONTROL 0
HTTP_X_CLIENT_SCHEME https
HTTP_X_FORWARDED_FOR 216.73.216.255
HTTP_ALI_SWIFT_STAT_HOST www.wangzhan360.com
HTTP_ALI_SWIFT_LOG_HOST www.wangzhan360.com
HTTP_ALI_CDN_REAL_IP 216.73.216.255
HTTP_ALI_CDN_REAL_PORT 39806
HTTP_EAGLEEYE_TRACEID 0819529f17799769137801315e
HTTP_VIA us26.l1, l2cm9-2.l2
HTTP_HOST www.wangzhan360.com
PATH_INFO
REDIRECT_STATUS 200
SERVER_NAME wangzhan360.com
SERVER_PORT 443
SERVER_ADDR 172.17.12.16
REMOTE_PORT 29342
REMOTE_ADDR 42.96.223.32
SERVER_SOFTWARE nginx/1.24.0
GATEWAY_INTERFACE CGI/1.1
HTTPS on
REQUEST_SCHEME https
SERVER_PROTOCOL HTTP/1.1
DOCUMENT_ROOT /www/wwwroot/www.wangzhan360.com/public
DOCUMENT_URI /index.php
REQUEST_URI /News/1789.html
SCRIPT_NAME /index.php
CONTENT_LENGTH
CONTENT_TYPE
REQUEST_METHOD GET
QUERY_STRING s=/News/1789.html
SCRIPT_FILENAME /www/wwwroot/www.wangzhan360.com/public/index.php
FCGI_ROLE RESPONDER
PHP_SELF /index.php
REQUEST_TIME_FLOAT 1779976913.7978
REQUEST_TIME 1779976913