views:

17

answers:

0

I have a colorbox which shows a hidden div when a link is clicked. within the div being shown in the colorbox is a usercontrol. its basically a subscribe to newsletter form that adds them to our customer db. For some reason the button to submit the form will not work in the colorbox, but it will if i move it outside of the hidden div. This is a problem i have encountered before and got around it by creating a iframe in the hidden div to a blank page with the usercontrol on it, but im sure there must be a simpler solution.

Markup :

<div style='display:none'> 
    <div id='SignUpForm' style='padding:10px; background:#fff;'>
        <umbraco:Macro Alias="SignUpUserControl" runat="server"></umbraco:Macro>
    </div> 
</div>

JavaScript :

$(document).ready(function () {
    $(".openSignUpForm").colorbox({
        width  : "50%",
        inline : true,
        href   : "#SignUpForm"
    });
});

btw. i am using umbraco cms, the macro is the reference to the usercontrol. but i still have the same problem if i add the usercontrol to the page the conventional way.