Home > Backend Development > PHP Tutorial > Detailed explanation of header jump and include inclusion issues_PHP tutorial

Detailed explanation of header jump and include inclusion issues_PHP tutorial

WBOY
Release: 2016-07-21 15:15:40
Original
808 people have browsed it

The registration process uses a single entrance. The core judgment is at the checkip. You only need to make a game_id judgment at the template program that has not been authenticated by real name. Because I was too sure and eager to get off work, coupled with the nervousness of everyone urging me, I was confused all of a sudden and made two mistakes: First, the game_id was judged in advance, resulting in many subsequent variables not being passed to the destination page; The second is that they do not understand the meaning of header jump and include, and directly use header to jump.

The page after the header jump cannot inherit variables and other elements from the previous page. For example:
a.php file

$userEname = "crystal";
$ userCname = "Chengcheng";
//your code
........................
header("location:b.php");
//your code
.............

If in b $userEname is referenced in the .php file, what do you think the result is? Okay, no more fuss, $userEname = null at this time. If you use include to include b.php, you can avoid the problem of $userEname being empty. Peng reminded me of this.
Postscript: I finished it at close to 9 o'clock, and Peng waited until I finished it before daring to go home. I give you a thumbs up for a dedicated person. The most pitiful person was Xiaobai. I originally promised to go shopping with her after get off work, but after waiting at the company for 2 hours, I still successfully let her go. It seems that there are still many cases like this. I guess she will never go shopping with me again... Hey~ Programmer, I really can’t afford to be hurt!

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/326030.htmlTechArticleThe registration process adopts a single entrance. The core judgment is at checkip. It only needs to be done at the template program without real-name authentication. Just judge by a game_id. Because I am too sure and eager to get off work...
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