Thursday 21 November 2019

html - Trouble With If statement PHP




I have been scripting PHP for for about 9 months now and im starting to run into a problem with my if conditions. This has never happened before.



if ($reason != "9ee1e1f4fbf1"){
XXXXXXXXX
}


I even tried putting the 9ee1ef4fbf1 in parenthesis and that didnt work.
i keep getting this:




Parse error: syntax error, unexpected T_IF in /home/content/49/549/html/index.php on line 21

Answer



The problem is in the line above the if. Maybe forgot a semicolon?


No comments:

Post a Comment

php - file_get_contents shows unexpected output while reading a file

I want to output an inline jpg image as a base64 encoded string, however when I do this : $contents = file_get_contents($filename); print &q...