jQuery-Facebox - Popup is not working after repaint from AJAX
Posted
by Bragaadeesh
on Stack Overflow
See other posts from Stack Overflow
or by Bragaadeesh
Published on 2010-06-18T12:32:36Z
Indexed on
2010/06/18
12:43 UTC
Read the original article
Hit count: 467
Hi
I am having a set of Links in my page and I have attached the facebox jQuery functionality so that whenever a link is pressed, it will get a nice popup
<a href="coach_selector_popup?day=<%= day %>&hour=<%= hour %>" rel="facebox">
Below is the script that I use for 'facebox'ing.
<script type="text/javascript">
jQuery(document).ready(function($) {
jQuery('a[rel*=facebox]').facebox()
})
</script>
The above is working fine. But when I render it again on response to some AJAX call, the functionality is getting lost, meaning when I click on the link I am redirected to a page instead of a facebox popup.
I know that I need to do something when I repaint, can someone point me to the right direction?
© Stack Overflow or respective owner