JQuery datepicker not showing properly with css

user1960836

My problem is that the calender doesn't show properly (not using googles css) Here is my code:

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
     <link rel="stylesheet" href="http://code.jquery.com/ui/1.10.3/themes/smoothness/jquery-ui.css" />
     <script src="//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>      
     <link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css">   
     <script src="http://code.jquery.com/jquery-1.9.1.js"></script>    
     <script src="http://code.jquery.com/ui/1.10.3/jquery-ui.js"></script>
     <script>
         $(function () {
             $("#MainContent_startDate").datepicker();
             $("#MainContent_endDate").datepicker();
         });
     </script>
</asp:Content>


<asp:TextBox ID="startDate" CssClass="InfoData" runat="server" TextMode="Date" Visible="false"></asp:TextBox>

<asp:TextBox ID="endDate" CssClass="InfoData" runat="server" TextMode="Date" Visible="false"></asp:TextBox>

I have tried using IE, FF and Chrome. In IE it says at the bottom: "Only safe content is shown". If I then click "Show all content", then the datepicker shows properly with googles css. But in FF and Chrome I don't get this possibility. But I don't think that it should ask this at all, it should just show the datepicker with the right css, as shown on the jquery example. Any idea? I saw a many topics with this issue, but not exactly the same as mine

Thanks in advance

enter image description here

Adriien M

In your TextBox control add ClientIDMode="Static" to match the ID selector like

    <asp:TextBox ID="endDate" ClientIDMode="Static" runat="server" />

Then keep this header only and datetimepicker should work

    <link rel="stylesheet" href="http://code.jquery.com/ui/1.10.3/themes/smoothness/jquery-ui.css" />
    <script src="http://code.jquery.com/jquery-1.9.1.js"></script>
    <script src="http://code.jquery.com/ui/1.10.3/jquery-ui.js"></script>
    <script type="text/javascript">
          $(document).ready(function () {
             $("#startDate").datepicker();
             $("#endDate").datepicker();
         });
    </script>

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

CSS: Images not showing for JQuery datepicker

From Dev

JQuery datepicker month dropdown border not showing properly in firefox

From Dev

DatePicker in jQuery Not Showing Calendar

From Dev

JQuery datepicker not showing in JSP

From Dev

jquery datepicker not showing calender

From Dev

JQUERY UI DatePicker Calendar not showing

From Dev

jQuery datepicker not showing in my App

From Dev

.css() jquery not working properly

From Dev

Jquery datepicker year range not working properly

From Dev

jQuery datepicker does not update value properly

From Dev

jQuery UI datepicker doesn't work properly

From Dev

Jquery datepicker year range not working properly

From Dev

jquery ui datepicker setDate not working properly

From Dev

jQuery UI Datepicker showing incorrect week number

From Dev

Jquery Datepicker placeholder not showing after blur

From Dev

setDate not showing correct month - jQuery Datepicker

From Dev

jQuery datepicker not showing next years dates

From Dev

showing Jquery ui datepicker on click of asp:linkbutton

From Dev

Bootstrap datepicker is not showing calender after cloning in jquery

From Dev

Jquery datepicker showing wrong date for leap year

From Dev

DatePicker not showing properly on a modal window in Bootstrap 3 (Safari/Chrome)

From Dev

Table CSS applying to Jquery Datepicker

From Dev

css trying to resize jQuery datepicker

From Dev

jQuery UI DatePicker: no CSS, no selection

From Dev

Multiple buttons in CSS + Button with an image not showing properly

From Dev

My css is not showing properly using codeIgniter

From Dev

HTML and CSS layout not showing properly on smartphone

From Dev

jquery rain datepicker firefox CSS not working

From Dev

jQuery ui - datepicker: month and year dropdown css

Related Related

  1. 1

    CSS: Images not showing for JQuery datepicker

  2. 2

    JQuery datepicker month dropdown border not showing properly in firefox

  3. 3

    DatePicker in jQuery Not Showing Calendar

  4. 4

    JQuery datepicker not showing in JSP

  5. 5

    jquery datepicker not showing calender

  6. 6

    JQUERY UI DatePicker Calendar not showing

  7. 7

    jQuery datepicker not showing in my App

  8. 8

    .css() jquery not working properly

  9. 9

    Jquery datepicker year range not working properly

  10. 10

    jQuery datepicker does not update value properly

  11. 11

    jQuery UI datepicker doesn't work properly

  12. 12

    Jquery datepicker year range not working properly

  13. 13

    jquery ui datepicker setDate not working properly

  14. 14

    jQuery UI Datepicker showing incorrect week number

  15. 15

    Jquery Datepicker placeholder not showing after blur

  16. 16

    setDate not showing correct month - jQuery Datepicker

  17. 17

    jQuery datepicker not showing next years dates

  18. 18

    showing Jquery ui datepicker on click of asp:linkbutton

  19. 19

    Bootstrap datepicker is not showing calender after cloning in jquery

  20. 20

    Jquery datepicker showing wrong date for leap year

  21. 21

    DatePicker not showing properly on a modal window in Bootstrap 3 (Safari/Chrome)

  22. 22

    Table CSS applying to Jquery Datepicker

  23. 23

    css trying to resize jQuery datepicker

  24. 24

    jQuery UI DatePicker: no CSS, no selection

  25. 25

    Multiple buttons in CSS + Button with an image not showing properly

  26. 26

    My css is not showing properly using codeIgniter

  27. 27

    HTML and CSS layout not showing properly on smartphone

  28. 28

    jquery rain datepicker firefox CSS not working

  29. 29

    jQuery ui - datepicker: month and year dropdown css

HotTag

Archive