Reply to Re: question about @

Your name:

Reply:


Posted by David Gillen on 11/15/06 16:46

An noise sounding like Pedro Graca said:
> sk wrote:
>> what is the @ used for....
>
> It's used to eliminate error messages generated by an expression.
> http://www.php.net/manual/en/language.operators.errorcontrol.php
>
> Example:
>
> <?php
> error_reporting(E_ALL);
> ini_set('display_errors', '1');
>
> unset($bar, $q);
>
> $foo = $bar; // use of uninitialized variable ($bar)
> $bar = @ $q; // error message suppressed
> ?>
>
Exactly what he said. Additionally it would be considered bad practice, and
you are far better handling errors in your script appropriately instead of
hiding them.

D.
--

/(bb|[^b]{2})/
Trees with square roots don't have very natural logs.
What's the difference between ignorance and apathy? Who knows? Who cares?

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация