我有这样的PHP代码 -为什么我的PHP包含功能无法正常工作?
<?php include('res/scripts/php/content_type/form_contents/birth_date_form.php?type=register&query=birth_month'); ?>
正如你可以看到,我包括它?type
和&query
,所以它是错误的或者有别的东西哪去错了。因为它显示了我下面的错误---
Warning: include(res/scripts/php/content_type/form_contents/birth_date_form.php?type=register&query=birth_month) [function.include]: failed to open stream: No error in C:\xampp\htdocs\mysharepoint\1.1\res\scripts\php\content_type\register_form.php on line 82
Warning: include() [function.include]: Failed opening 'res/scripts/php/content_type/form_contents/birth_date_form.php?type=register&query=birth_month' for inclusion (include_path='.;\xampp\php\PEAR') in C:\xampp\htdocs\mysharepoint\1.1\res\scripts\php\content_type\register_form.php on line 82
但是,消除?type=register&query=birth_month
后,我没有得到任何错误! 所以你有什么建议,请让我知道。
在此先感谢!
您是否试图将文件加载为php - 然后运行脚本,或加载脚本在运行后生成的内容? – 2011-03-30 17:31:04