Deprecated: parse_url(): Passing null to parameter #1 ($url) of type string is deprecated in /www/wwwroot/blog_qqvbc_com/usr/plugins/Access/Access_Core.php on line 339

Deprecated: parse_url(): Passing null to parameter #1 ($url) of type string is deprecated in /www/wwwroot/blog_qqvbc_com/usr/plugins/Access/Access_Core.php on line 392

Deprecated: parse_url(): Passing null to parameter #1 ($url) of type string is deprecated in /www/wwwroot/blog_qqvbc_com/usr/plugins/Access/Access_Core.php on line 394
bootstrap 的日期选择插件 datetimepicker插件 的显示位置有问题? - Joyber 的博客

你可以尝试在参数中加上container属性,比如

{
...
container: '#j-datetimepicker-wrap'
...
}

这个属性设置为你的控件放到哪个容器对象中里面。

这个容器(j-datetimepicker-wrap) 请加上 position: relative; 的样式,这是为了计算控件需要的偏移量,就是坐标位置。

源代码有这么一行

this.container = options.container || 'body';

如果你没有设置container这个属性,那么默认你的日历控件是在body里面

如果你绑定了弹出层div,那么日历控件就和弹出层是一体的了

标签: datetimepicker

仅有一条评论

  1. ChuHai5 ChuHai5

    前来学习!!!!

添加新评论