Click here to Skip to main content
15,896,912 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have two modelpop in 1 Child page's content place holder. and i have write the java script for close modelpop in Header content placeholder. But it...

HTML
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">

    <script type="text/javascript" language="javascript">
        function closePopup() {
            $find('ctl00_ContentPlaceHolder1_ModalPopupExtender1').hide();
            // $find('ContentPlaceHolder1_ModalPopupExtender1').hide();

            //var phn = document.getElementById('ctl00_ContentPlaceHolder1_txtAdmisnNo');
            //document.getElementById('ctl00_ContentPlaceHolder1_txtAdmisnNo').value = "";
            document.getElementById('ContentPlaceHolder1_ModalPopupExtender1').value = "";
        }
        //        function showPopup() {
        //            $find('ctl00_ContentPlaceHolder1_ModalPopupExtender1').hide();
        //        }
        function closePopup1() {
            $find('ctl00_ContentPlaceHolder1_ModalPopupExtender2').hide();
            // $find('ContentPlaceHolder1_ModalPopupExtender1').hide();

            //var phn = document.getElementById('ctl00_ContentPlaceHolder1_txtAdmisnNo');
            //document.getElementById('ctl00_ContentPlaceHolder1_txtAdmisnNo').value = "";
            document.getElementById('ContentPlaceHolder1_ModalPopupExtender2').value = "";
        }
    </script>
Posted
Updated 25-Nov-12 22:27pm
v2
Comments
Dinesh Ambaliya 26-Nov-12 6:49am    
Use ModelPopUpBehavior and close it using JS.

1 solution

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900