html - 定位日历
问题描述
您如何定位日历以像演示一样浮动在页面中?
提供的示例将日历固定在左上角.. 已修复。编码
<style>
html, body {
overflow: hidden; /* don't do scrollbars */
font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
font-size: 14px;
}
#calendar-container {
width: 700px;
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
}
.fc-header-toolbar {
/*
the calendar will be butting up against the edges,
but let's scoot in the header's buttons
*/
padding-top: 1em;
padding-left: 1em;
padding-right: 1em;
}
.td_Info{
width: 300px;
}
.td_calendar{
width: 700px;
}
</style>
</head>
<body>
<div>
<h1>My Page</h1>
</div><br/>
<table><tr>
<td class="td_Info">INFO<br>
more<br>
more <br>
more <br>
more<br></td>
<td class="td_cal"><div style="max-width: 500px;">
<div id='calendar-container'>
<div id='calendar'></div>
</div>
</td></tr>
</table>
</div>
</body>
</html>
渲染 日历
我知道这是因为样式上的固定位置..但是当我取下它并放置类似相对的东西时..日历不再正确呈现..
解决方案
推荐阅读
- angular - 对象属性的Angular中的绑定问题
- amazon-web-services - 存储在 AWS S3 中时,parquet 文件是否可拆分?
- laravel - 如何在数据表中使用 if else 添加来自控制器的列
- postgresql - 在 docker 中使用 pg_dump 时没有合适的本地集群错误
- php - Laravel 6.x - 配置文件中未定义的函数
- service-worker - 为什么 Service Worker 会停止对服务器的 http/https 请求?
- azure - Azure 虚拟机,无法从 Internet 访问
- c++ - iostream 运算符重载的 C++ 异常规范
- r - R - lrm逻辑回归系数/优势比?
- javascript - 如何将一个函数放在返回之外,然后从 onChange 反应中调用它?