Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to set the show position of datepicker?

dear i have a datepicker inside my form. after i click the textfield, datepicker show to up(reverse with drop down). how do i do if i want to show datepicker dropdown not dropup? http://img413.imageshack.us/img413/1460/screenshot5g.png

like image 974
klox Avatar asked Aug 13 '10 04:08

klox


People also ask

How do you set a datepicker position?

To change the position of the jQuery UI Datepicker just modify . ui-datepicker in the css file. The size of the Datepicker can also be changed in this way, just adjust the font size.

How do I change my datepicker orientation?

at Datepicker Link, just click the Download Development and get latest JS which include the orientation options. In the JS given defaults are: var defaults = $. fn.

How can show datepicker in ASP NET MVC?

Go to New project and select the Web tab and select ASP.Net Web Application. Provide a suitable name for your project, such as DateTimeDemo, and click the OK button. Then the following screen will appear. Select the MVC tab and click the OK button.


1 Answers

 $('.datetime').datepicker({
     dateFormat: 'm/d/yy',
     beforeShow: function (input, inst) {
         var offset = $(input).offset();
         var height = $(input).height();
         window.setTimeout(function () {
             inst.dpDiv.css({ top: (offset.top + height + 4) + 'px', left: offset.left + 'px' })
         }, 1);
     }

 });
like image 169
Igor Zelmanovich Avatar answered Sep 28 '22 12:09

Igor Zelmanovich