2

I have a problem executing onclose event multiple time on page. I have used handler:iframe to display view in squeezebox modal.

I have written following javascript:-

on child page

<script type="text/javascript">
    jQuery(document).ready(function() {
        jQuery("#add_agent").on('click',function (e) {
            e.preventDefault();
            jQuery('#agentsList input:checked').each(function() {
                window.parent.agents.push(jQuery(this).val());
            });
            window.parent.SqueezeBox.close();
        });
    });
</script>

on parent page

<script type="text/javascript">
    window.agents = [];
    window.SqueezeBox.addEvent('onClose',function() {
        if(window.agents.length !== 0){
            jQuery("#agentChecked").css('display','block');
</script>

onClose event on parent page works fine for the first time. But at second time of closing modal, this event doesn't response.

What should I Do???

0

1 Answer 1

0
window.SqueezeBox.initialize({
        onClose:function(){
        }
});

This Solved Problem

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.