Header (& quot; location & quot;. $ url) cannot be used in the if statement? Header (location. $ url) cannot be used when the if statement does not take effect. generally, it does not take effect. phpheader () ------ solution-header ("location ". $ url) cannot be used in the if statement?
Header ("location". $ url) cannot be used in the if statement
In general, what are the cases that do not take effect?
Php header ()
------ Solution --------------------
What about colons? Where?
------ Solution --------------------
Bottom
If ($ mhavelogin = 1) {header ("Location:". $ GameLoginUrl);} else {?> You have not logged on. please log on first
Change
If ($ mhavelogin = 1) {header ("Location:". $ GameLoginUrl);} else {echo 'you have not logged on yet. please log on first ';}
For specific reasons, Baidu should look for some notes about header function usage.
------ Solution --------------------
Write PHP code. in some cases, you must strictly follow your own requirements.
No output before header
In some UTF8 formats, BOM does not work either.
Also, redirection can be implemented in js.
Echo"