JavaScript Errors

Discussion in 'Javascript' started by PaVaN KuMaR, Jun 10, 2011.

  1. PaVaN KuMaR

    PaVaN KuMaR Guest

    Hello Everyone,

    Not sure whether its the correct forum or not for my scenario.

    For finding the existing JS errors on a web page load, we generally
    manually check the status bar in Internet Explorer and Error Console
    in Firefox browser. But I would like to know if there is a way to
    identify/capture these java script errors Programmatically on
    different browsers. I believe there should be a way to do this, but
    couldn't get any details over the Internet.

    Thanks,
    Pavan Kumar.
     
    PaVaN KuMaR, Jun 10, 2011
    #1
    1. Advertising

  2. PaVaN KuMaR

    Tim Streater Guest

    In article <>,
    Stefan Weiss <> wrote:

    > On 10/06/11 23:32, PaVaN KuMaR wrote:
    > > For finding the existing JS errors on a web page load, we generally
    > > manually check the status bar in Internet Explorer and Error Console
    > > in Firefox browser. But I would like to know if there is a way to
    > > identify/capture these java script errors Programmatically on
    > > different browsers. I believe there should be a way to do this, but
    > > couldn't get any details over the Internet.

    >
    > You could try window.onerror on those browsers that support it. Other
    > than that, try..catch might be an option for runtime errors, but that
    > won't work for syntax errors.


    When Safari 5.1 is released I'll be putting just this into my app. I'll
    be sending the info caught by the event to the server side of my app so
    I can log the error.

    --
    Tim

    "That excessive bail ought not to be required, nor excessive fines imposed,
    nor cruel and unusual punishments inflicted" -- Bill of Rights 1689
     
    Tim Streater, Jun 11, 2011
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Mark Goldin

    Errors, errors, errors

    Mark Goldin, Jan 17, 2004, in forum: ASP .Net
    Replies:
    2
    Views:
    1,035
    Mark Goldin
    Jan 17, 2004
  2. SenthilVel
    Replies:
    0
    Views:
    982
    SenthilVel
    Jun 7, 2006
  3. George1776

    Out-of-memory errors and caching errors.

    George1776, Aug 28, 2006, in forum: ASP .Net
    Replies:
    2
    Views:
    1,367
    George1776
    Sep 14, 2006
  4. Lance Wynn
    Replies:
    1
    Views:
    1,922
    Lance Wynn
    Feb 3, 2008
  5. yawnmoth
    Replies:
    97
    Views:
    4,811
    Bent C Dalager
    Feb 27, 2009
Loading...

Share This Page