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 () { ...}).

Reply via email to