3 ms·
Error suppression: bad. Exception handling: good. Some of my earliest code has stuff like @mysql_query() because many books recommend this...and that's not even
by thomasmallen 18y ago
Error suppression: bad. Exception handling: good. Some of my earliest code has stuff like @mysql_query() because many books recommend this...and that's not even a reasonable place to suppress an error!
- jfarmer 18y agoNot only is it bad practice, but as the article points out, there is a performance hit. The reason is because @ makes the PHP engine switch between rendering modes. Basically it's as if you have an extra <?php ?> in there. Do that a lot and it adds up. So it's bad on every level.