Home >Backend Development >PHP Tutorial >PHP method to determine whether there are Get parameters_PHP tutorial

PHP method to determine whether there are Get parameters_PHP tutorial

WBOY
WBOYOriginal
2016-07-13 10:30:32929browse

You can use the following method to determine

Copy code The code is as follows:

if(is_array($_GET)&&count($_GET)> ;0)//Judge whether there is a Get parameter
{
if(isset($_GET["para"]))//Judge whether the required parameters exist. isset is used to detect whether the variable is set and returns true or false
{
$para=$_GET["para"];//Exists
}
}

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/765159.htmlTechArticleYou can use the following method to judge the copied code. The code is as follows: if(is_array($_GET)count($_GET)0) //Judge whether there is a Get parameter { if(isset($_GET["para"]))//Judge whether the required parameters exist,...
Statement:
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