我想在头文件中包含一个文件:
可湿性粉剂内容/主题/ THEMENAME / header.php文件
我用来包含的代码是:
include("../../plugins/booking/informationform.php");
虽然我想要包含的文件位于此目录中:
可湿性粉剂内容/插件/预订/ informationform.php
所以这给我一个错误:
警告:include(../../ plugins / booking / informationform.php)[function.include]:无法打开流:没有这样的文件或目录 在 /home/zapptv/domains/tvworkshop.com/public_html/wp-content/themes/tvworkshop/header.php 在线100
警告:include(../../ plugins / booking / informationform.php) [function.include]:无法打开流:没有这样的文件或目录 在 /home/zapptv/domains/tvworkshop.com/public_html/wp-content/themes/tvworkshop/header.php 在线100
警告:include()[function.include]:打开失败 '../../plugins/booking/informationform.php'包含在内 (include_path ='。:/ usr / local / lib / php')in /home/zapptv/domains/tvworkshop.com/public_html/wp-content/themes/tvworkshop/header.php 在线100
但是当我将文件复制到标题所在的同一目录中并且仅包含文件名时,它不会给出任何错误并且包括成功。