•
•
•
•
What is DaniWeb IT Discussion Community?
You're currently browsing the PHP section within the Web Development category of DaniWeb, a massive community of 391,814 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,525 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our PHP advertiser: Lunarpages PHP Web Hosting
Views: 345 | Replies: 6 | Solved
![]() |
•
•
Join Date: Feb 2008
Location: Gurgaon India
Posts: 64
Reputation:
Rep Power: 1
Solved Threads: 9
•
•
Join Date: Nov 2007
Location: Bangalore, India
Posts: 3,098
Reputation:
Rep Power: 8
Solved Threads: 238
@ doesn't help it error handling, but it supresses the errors.
This above code, supresses the warning if there is something wrong with the query. Its not a good practice to have @, because it makes your life very difficult to know where the exact error is.
php Syntax (Toggle Plain Text)
if(@mysql_num_rows($result) > 0){ //do something
This above code, supresses the warning if there is something wrong with the query. Its not a good practice to have @, because it makes your life very difficult to know where the exact error is.
Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning.
*PM asking for help will be ignored*
*PM asking for help will be ignored*
•
•
Join Date: Mar 2008
Posts: 153
Reputation:
Rep Power: 1
Solved Threads: 19
•
•
•
•
. Its not a good practice to have @, because it makes your life very difficult to know where the exact error is.
I agree. I have absolutely never used it.... another lazy practice even worse than short tags.
Good code has error handling, not error suppression.
Matti Ressler
Suomedia
If you want your dreams to come true, the first thing you must do is to wake up....
Suomedia - Dynamic Content Management
Suomedia - Dynamic Content Management
![]() |
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
•
•
•
•
•
•
•
•
DaniWeb PHP Marketplace
Other Threads in the PHP Forum
- Previous Thread: Need help with PHP site and IE - Operation Aborted
- Next Thread: php: populating 3 listboxes



Linear Mode