Monday, June 3, 2024
 Popular · Latest · Hot · Upcoming
33
rated 0 times [  35] [ 2]  / answers: 1 / hits: 78269  / 11 Years ago, tue, february 4, 2014, 12:00:00

In PHP and other languages there are ways to suppress error/warning messages.



Is there a way in javascript or jquery to prevent errors and warnings from being written to the console log?


More From » jquery

 Answers
17

You can handle errors to some extent but if error is not handled by you then it goes to browser and you can not stop browser showing it. You can write code in such a way that you get minimum error and using try-catch where possible to handle the exceptions.



try
{
//statements suspected to throw exception.
}
catch(e)
{
}

[#72739] Monday, February 3, 2014, 11 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
trinityr

Total Points: 49
Total Questions: 107
Total Answers: 96

Location: Mayotte
Member since Fri, Oct 1, 2021
3 Years ago
;