jQuery: The Write Less, Do More JavaScript Library

 « Return to Thread: jQuery Countdown and close button

Re: jQuery Countdown and close button

by Keith-117 :: Rate this Message:

Reply to Author | View in Thread


The problem is that the closeButton setup is called immediately it is
encountered - before the button itself exists - so no match and
nothing happens. You need to move the $('#closeButton').click(function
() { ... }); inside the document ready call: $(function () { ...}).

 « Return to Thread: jQuery Countdown and close button