How to wrap the datepicker in a new div?
问题 I need to put my datepicker in a new div, that will be a (shadow-)border-div. I've tried the following: beforeShow: function (input) { $(input).datepicker("widget") .find(".ui-datepicker-header, ui-datepicker-calendar") .wrapAll("<div class='datepickerBorder'/>"); } But it does not work. Additionally I've tried to wrap the whole picker, but then the border-div has not the same position, size, etc. 回答1: The datepicker control is absolutely positioned. Wrapping it inside an element will not