I’ve run into a very weird issue that I’ve neither seen before nor do I have any clue how to fix it. This happened when I redesigned/coded my rush page functionality on the ZAX Portal.
My weird issue is that when I redeclare the .click() functionality on an element on my page, the code executes the actual functions within the new declaration. Sounds weird right? Here’s the setup:
In my showRushee() function, I change our image’s source (it’s a + to – image), remove the previous onclick function, and add a new .click() functionality that calls hideRushee().
There’s some more that happens afterward, but it seems pretty straight forward right? Well, here’s a screenshot of what is actually happening using IE’s web developer debugger.
I ended up putting a breakpoint within the hideRushee() function in order to see if it was being called. Once it reached the breakpoint, I went one step up in the call stack which is what you see above.
I don’t really understand why this is happening. This code works in Firefox, Chrome and Safari just perfectly. This code also works after you click on the expander once again, so it only happens the first time it is clicked. Does anyone have any idea what’s going on?