-
How can I see the error message when page is loaded?
Hello,
In my code, I create a php file by using the contents of a textarea that is used for trying PHP code.
If the php file has no syntax errors, it is loaded in the bwowser very well. But if it has syntax error(s) in it (i.e. writing ech instead of echo), I see a white page. But, instead of a white page I want the user to see the related error message (in this case "Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING in C:\xampp\htdocs\tez\test.php on line 4").
If anyone can help me to solve this problem, I will be very happy.
Thank you.
-
-
I assume you added error_reporting(E_ALL) to your primary PHP file, so I'd say you should include the textfile as PHP. It should be able to echo your errors.
Hopefully it'll work for you.
-
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
Bookmarks