HTML&;CSS-显示部分选框框
我想在一个容器里放一个小的或“部分”的框。基本上我想显示4个内角。类似于以下内容:我想知道我如何才能做到这一点?感谢您的帮助HTML&;CSS-显示部分选框框,html,css,Html,Css,我想在一个容器里放一个小的或“部分”的框。基本上我想显示4个内角。类似于以下内容:我想知道我如何才能做到这一点?感谢您的帮助 +--------------------------------------------+ ---> this is main container | +-- --+ | | | | | |
+--------------------------------------------+ ---> this is main container
| +-- --+ |
| | | |
| |
| |
| |
| |
| |
| | | |
| +-- --+ |
+--------------------------------------------+
你的意思是这样的:
<div style='padding: 15px'>
<div style='background: url(...)'></div>
</div>
??如果高度和宽度未知,可以使用用于在4个div上生成圆角的方法,例如
<!DOCTYPE html>
<html>
<head></head>
<body>
<div id='the_container' style='border: 1px solid #000; width:90%; height:90%; top: 5%; left: 5%; position: absolute;'>
<div id='corner_t_l' style='border-top: 1px dashed #000; border-left: 1px dashed #000; top: 10px; left: 10px; width: 30px; height: 30px; position: absolute;'></div>
<div id='corner_t_r' style='border-top: 1px dashed #000; border-right: 1px dashed #000; top: 10px; right: 10px; width: 30px; height: 30px; position: absolute;'></div>
<div id='corner_b_r' style='border-bottom: 1px dashed #000; border-right: 1px dashed #000; bottom: 10px; right: 10px; width: 30px; height: 30px; position: absolute;'></div>
<div id='corner_b_l' style='border-bottom: 1px dashed #000; border-left: 1px dashed #000; bottom: 10px; left: 10px; width: 30px; height: 30px; position: absolute;'></div> </div>
</body>
</html>
现场示例:你有没有关于它应该是什么样子的图像示例?是的,那会有用的,但是我一直在寻找纯粹使用每个角上的边框和div来实现它。这可行吗?