error-suppression

Php function argument error suppression, empty() isset() emulation

I'm pretty sure the answer to this question is no, but in case there's some PHP guru is it possible to write a function in a way where invalid arguments or non existent variables can be passed in and php will not error without the use of '@' Much like empty and isset do. You can pass in a variable you just made up and it won't error. ...

Suppress error with @ operator in PHP

In your opinion, is it ever valid to use the @ operator to suppress an error/warning in PHP whereas you may be handling the error? If so, in what circumstances would you use this? Code examples are welcome. Edit: Note to repliers. I'm not looking to turn error reporting off, but, for example, common practice is to use @fopen($file); ...

PHP alias @ function

I'm new to PHP and I'm confused seeing some examples calling a function with a @ prefix like @mysql_ping(). What is it for? Googling / searching is not much of a help since @ gets discarded and 'alias' is not good enough keyword. ...

What is the best practice for outputting a variable which may or may not contain anything in PHP?

I am developing an application and want to display a form that will be filled in if editing the form, but will not be if the form will be a new entry. I believe the least verbose way of doing this is to have just one form and to suppress any errors for echoing my variables so that nothing will be printed if it is a new form (since the v...

How do I suppress a thread.abort() error C# ?

I am showing a splash screen on a background thread while my program loads. Once it loads I am aborting the Thread as it's only purpose was to show a Now Loading splash form. My problem is that when aborting a Thread it throws a ThreadAbortException that the user can just click Continue on. How do I deal with this? I was trying to ...

What is the use of @ symbol in php?

I have seen using @ in front of certain functions like following: $fileHandle = @fopen($fileName, $writeAttributes); What is the use of this symbol? ...

Error Suppression @ Not Working

I've been happily using the error suppression operator on my PHP dev setup. But recently have gotten hit with Notices like so: Notice: Uninitialized string offset: 0 in C:\websites\xxx\htdocs\includes\myscript.php on line 35 Line 35: $file_name = @$File['file_name']; I have display_errors on, and error_reporting set to 6143 (E_AL...

what does @ means before include or require

hey guys i wonder what does @ means when we use it before include or require in php ?! such as : @include('block.php'); maybe its a noob question , but i need to know it guys ?! so sorry for that ...

How to use cppcheck's inline suppression filter option for C++ code?

I would like to use cppcheck for static code analysis of my C++ code. I learned that I can suppress some kind of warnings with --inline-suppr command. However, I can find what "suppressed_error_id" I should put in the comment: // cppcheck-suppress "suppressed_error_id" ...