hello,
I try to get a click event in a fancybox. the fancybox is displayed but nothing happens when the user clicks
in the fancybox. I use the following code:
- <script type="text/javascript"><!--
$(document).ready(function() {
$('div#nllayer').click(function () {
alert("test");
});
});
--></script>
<div id="nllayer" width="590" height="400" style="display:none;">
<div id="psnl" style="padding: 120px 0 0 10px;background-image: url(images/bg_psnl.jpg); width: 580px; height 53px;text-align:left;">
<input type="checkbox" value="psnl" class="la" id="psnl" />
</div>
<div id="csnl" style="padding: 120px 0 0 10px; background-image: url(images/bg_csnl.jpg); width: 580px; height: 27px;text-align:left;">
<input type="checkbox" value="csnl" class="la" id="csnl"/>
</div>
<table width="590" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="10" bgcolor="#D9EEF7"> </td>
<td valign="top" bgcolor="#D9EEF7">
<div id="newsletterbox">
<table border="0" cellspacing="0" cellpadding="0">
<!-- CONTENT -->
</table>
</div>
</td>
<td width="10" bgcolor="#D9EEF7"> </td>
</tr>
</table>
</div>
div#nllayer is the content in the fancybox. I try to catch the event with the javascript:
- $('div#nllayer').click(function () {
alert("test");
});
but it doesn't work :-(