我遇到了问题并且没有想法。
我试图从 URL 获取参数,但 PHP 坚持说该变量未定义。
网址是
http://localhost/trendwatcher/index.php?date=2014-10-18
脚本是这样的
<?php include "header.php"; ?>
<section id="stats">
Showing trends for <?php echo $GET_["date"]; ?>
</section>
最后,错误:
Showing trends for
Notice: Undefined variable: GET_ in C:\xampp\htdocs\trendwatcher\index.php on line 4
有人有什么想法吗?
Thanks!
修复您的代码:
<section id="stats">
Showing trends for <?php echo $GET_["date"]; ?>
</section>
to
<section id="stats">
Showing trends for <?php echo $_GET["date"]; ?>
</section>
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)