Opened 5 years ago

Closed 5 years ago

#10136 closed bug (invalid)

DatePicker not working in modal popup page

Reported by: sanjeebkumarpatra78@… Owned by: sanjeebkumarpatra78@…
Priority: minor Milestone: none
Component: ui.datepicker Version: 1.11.0
Keywords: Cc:
Blocked by: Blocking:

Description

Dear Sir/Madam

I am using jQuery datepicker. but it is not working as expected.Is there any options to upload my example.It would be nice.

Regards Sanjeeb Kumar Patra

Default.aspx


<html xmlns="http://www.w3.org/1999/xhtml" > <head runat="server">

<title>Untitled Page</title> <link rel="stylesheet" href="code.jquery.com/ui/1.11.0/themes/smoothness/jquery-ui.css">

<script src="code.jquery.com/jquery-1.10.2.js"></script> <script src="code.jquery.com/ui/1.11.0/jquery-ui.js"></script> <link rel="stylesheet" href="StyleSheet.css" /> <script> $(function() {

$( "#datepicker1" ).datepicker({

showOn: "both", buttonImage: "calendar.gif", changeMonth: true, changeYear: true, dateFormat:"M dd yy",

});

});

function fnOpenModal() {

$("#ui-datepicker-div").remove(); $('#frmBookDet').load('Default2.aspx',function(){ });

$('#frmBookDet').show();

} </script>

</head> <body>

<form id="form1" runat="server"> <div>

<p>Date: <input type="text" id="datepicker1"></p> <input id="Button1" type="button" value="button" onclick="fnOpenModal()" /></div>

</div> <div class="LoadingDiv" id="frmBookDet"> </form>

</body> </html>

Default2.aspx


<html xmlns="http://www.w3.org/1999/xhtml" > <head runat="server">

<title>Untitled Page</title>

<link rel="stylesheet" href="code.jquery.com/ui/1.11.0/themes/smoothness/jquery-ui.css">

<script src="code.jquery.com/jquery-1.10.2.js"></script> <script src="code.jquery.com/ui/1.11.0/jquery-ui.js"></script>

<script>

$(function() {

$( "#datepicker2" ).datepicker({

showOn: "both", buttonImage: "calendar.gif", changeMonth: true, changeYear: true, dateFormat:"M dd yy",

});

});

function fnClose() {

$('#datepicker1').datepicker('refresh'); $("#frmBookDet").hide(); $("#frmBookDet").html("");

} </script>

</head> <body style="background-color:green; height:100px;width:100px;">

<form id="form1" runat="server"> <div>

<p>Date:

<input id="Button1" style="z-index: 100; left: 56px; position: absolute; top: 112px"

type="button" value="button" onclick="fnClose();" />

<input type="text" id="datepicker2"></p>

</div> </form>

</body> </html>

StyleSheet.css


.LoadingDiv {

top:0; right:0; width:200px; height:400px; position:absolute; text-align:center; z-index:100000; display:none; background-color:Green;

}

step to produce bug select Date on Default.aspx page Click on button to open Default2 page select date and click on Button to close Default2 page again repeat In third time datepicker popup not open.

Change History (2)

comment:1 Changed 5 years ago by Scott González

Owner: set to sanjeebkumarpatra78@…
Status: newpending

Please use jsFiddle or jsbin as requested in the red box. You can add /show on a jsFiddle URL to get just the results page (not the full editor) for dealing with multiple pages.

comment:2 Changed 5 years ago by trac-o-bot

Resolution: invalid
Status: pendingclosed

Because we get so many tickets, we often need to return them to the initial reporter for more information. If that person does not reply within 14 days, the ticket will automatically be closed, and that has happened in this case. If you still are interested in pursuing this issue, feel free to add a comment with the requested information and we will be happy to reopen the ticket if it is still valid. Thanks!

Note: See TracTickets for help on using tickets.