I’m trying to debug a problem that happens on Safari 3.1 (but not in 3.2 or later, nor in any other browser, and yes, I’ve tried to close this is “upgrade your browser”, but the client won’t allow it). So I’ve thrown a bunch of alert('doing foo'); statements in my javascript file, but none of them are showing up. I can type an alert command in the console and it does show up. So why are the alerts in the code not showing up?
Also, any general hints on how do debug javascript in such an ancient browser would be appreciated.
And to answer the questions below – I put some of those alerts in code that I know is executing because it’s doing the right thing. And I turned off cache in the browser Developer menu.
My guess is you are not clearing your cache or your code is throwing an error before it hits any of the alert statements.