Article Categories
- All Categories
-
Data Structure
-
Networking
-
RDBMS
-
Operating System
-
Java
-
MS Excel
-
iOS
-
HTML
-
CSS
-
Android
-
Python
-
C Programming
-
C++
-
C#
-
MongoDB
-
MySQL
-
Javascript
-
PHP
Selected Reading
What does the '@' prefix do in PHP?
The ‘@’ symbol suppresses errors from getting displayed on the screen.
PHP supports an error control operator, i.e the sign (@). When it is prepended to an expression in PHP, error messages that could get generated when it uses that expression will be ignored.
If the track_errors attribute is enabled, the error message generated by the expression will be saved in the variable named $php_errormsg. This variable will be overwritten each time on every error.
It is always suggested to write code that works relevantly with error states/conditions.
Advertisements
