Notice: Undefined index: page in E:PHPtest.php on line 14_PHP教程

WBOY
Release: 2016-07-21 15:33:11
Original
996 people have browsed it

The only way to cure the symptoms but not the root cause is to modify the reporting part in php.ini so that the notice does not display
error_reporting = E_ALL; display all errors, warnings and notices
to
error_reporting = E_ERROR & ~E_NOTICE & ~ E_WARNING

Otherwise
isset($_GET["page"]) makes an if-else judgment!!

----The corrected source code is as follows----
if(isset($_GET["page"]))$page=$_GET["page"];
else $page=1;


www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/322659.htmlTechArticleThe only way to cure the symptoms but not the root cause is to modify the reporting part in php.ini so that the notice does not display error_reporting = E_ALL; display all errors, warnings and notices changed to error_reporting = E_ERROR...
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template