Incorporating a modal popup to display a login box has brought up an interesting challenge. The modal popup is situated in the master page and connected to a LogIn link. However, now there is a need to invoke the same modal popup from a child page using a different link button. While the current setup allows for calling the modal popup via the LogIn link on the master page, the goal is to introduce a second control (linkButton) on the child page that can trigger the master page's modalpop.
The attempted solution in the child page was as follows:
function LogIn2()
{
$find("programmaticModalPopupBehavior").show();
}
<asp:LinkButton ID="LinkButton1" runat="server" OnClientClick="LogIn2">Log in</asp:LinkButton>
For more insights, check out this resource discussing multiple TargetControls for the ModalPopup.
The question remains - how can the operational modal popup on the master page be summoned from a control on the child page?
Update:
This snippet is part of the masterpage:
<ajax:ModalPopupExtender ID="ModalPopupExtender1" runat="server" TargetControlID="linkLog" CancelControlID="linkClose" BackgroundCssClass="cssModal" PopupControlID="panelPopUp" BehaviorID="programmaticModalPopupBehavior" PopupDragHandleControlID="panelDrag"></ajax:ModalPopupExtender>