xhtml/mobile 1.2 DOCTYPE 导致奇怪的工件
我有以下 HTML
<html>
<body>
<div style="background:white;width:620px; height: 464px; overflow: hidden;">
<style>.v{width:100%;background: red;border:0px; color:#FFFFFF;text-align:
center; font-size: 11px;font-family:arial; vertical-align: middle;}</style>
<a target="_blank" href="http://www.google.com/">
<div style="height:28px;width:620px;display:table-cell" class="v">Video</div>
</a><video style="background:black" height="408px" width="100%" ></video>
<a target="_blank" >
<div class="v" style="height:28px;width:620px;display:table-cell">Bottom</div></a></div>
When I use a DOCTYPE with this I get a white line below the Video, otherwise it renders fine. This is without DOCTYPE.And this is with doctype
<!DOCTYPE html PUBLIC "-//WAPFORUM//DTD XHTML Mobile 1.2//EN" "http://www.openmobilealliance.org/tech/DTD/xhtml-mobile12.dtd">
I tried tweaking CSS, but with no luck. Am I missing something?
I've the following HTML
<html>
<body>
<div style="background:white;width:620px; height: 464px; overflow: hidden;">
<style>.v{width:100%;background: red;border:0px; color:#FFFFFF;text-align:
center; font-size: 11px;font-family:arial; vertical-align: middle;}</style>
<a target="_blank" href="http://www.google.com/">
<div style="height:28px;width:620px;display:table-cell" class="v">Video</div>
</a><video style="background:black" height="408px" width="100%" ></video>
<a target="_blank" >
<div class="v" style="height:28px;width:620px;display:table-cell">Bottom</div></a></div>
When I use a DOCTYPE with this I get a white line below the Video, otherwise it renders fine. This is without DOCTYPE.
And this is with doctype <!DOCTYPE html PUBLIC "-//WAPFORUM//DTD XHTML Mobile 1.2//EN" "http://www.openmobilealliance.org/tech/DTD/xhtml-mobile12.dtd">
I tried tweaking CSS, but with no luck. Am I missing something?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
将“display:block”或“vertical-align:bottom”添加到视频元素的 CSS 中。
Add "display:block" or "vertical-align:bottom" to the css of your video element.