views:

26

answers:

3

I have a pop-up window in a web app that allows you to edit details of a job. You can also click a link to cancel/delete that job. But when I click that link right now after making some edits to it, nothing happens.

It behaves as if javascript was targeting it with "return: false;" so it does nothing. The URL is correct. How can I check if there is JS intercepting my click event, and where it's doing that? Can Console do that? I'm not sure how if so.

Thanks!

A: 

Firebug is an invaluable tool for helping you debug javascript / coding javascript applications. I would suggest installing it to see what your error is etc.

Alternatively, Firefox has an Error Console, which you can view Javascript errors as well.

Brad F Jacobs
But he doesn't have an error on the page?
Marko
I do not see him mentioning that there was not an error and gathering from the "error" tag, I took it there was an error :)
Brad F Jacobs
I use Firebug about 8 hours a day! It's not an official error, but the click is being intercepted and returned false and I was wondering if the Console could tell me where that JS is?
Jason Rhodes
A: 

In firebug you can debug your javascript code with:

console.log('text and '+variables);

You can click the console tab in firebug and see values. you can add a console.log line within your click handler to see if it's even getting inside the handler.

Catfish
Unfortunately I have the opposite problem. I dont know where the JS block that is intercepting my HTML link is! Was hoping for a location like Firebug does for CSS with "Inspect Element"
Jason Rhodes
I think it would be helpful if you could post some code or a link.
Catfish
A: 

chrome's developer tools will list all handlers registered for an event on an element. i don't know of any other tools that provide this info.

lincolnk
OK I need to check into how to access that specific info in the Developer Tools.
Jason Rhodes