[英]HTML5 frame with text on side- not fieldset/legend
I'm building a bootstrap base site, where I'm trying to create a frame with text attached along is't left side (see attached sketch-up image done in MS paint). 我正在建立一个引导基地,我试图在其中创建一个框架,该框架的文本不位于左侧(请参阅在MS Paint中完成的草图)。 So far to no avail. 迄今无济于事。
I attempted to use fieldset and legend, and have been able to create a title on top of the fieldset in the legend, but I cannot rotate the legend to sit on the side as I want to. 我尝试使用字段集和图例,并且已经能够在图例中的字段集的顶部创建标题,但是我无法旋转图例以使其位于侧面。 Furthermore, the fieldset/legend solution does not work properly in IE, as the legend keeps flying around uncontrollably. 此外,由于图例不断不受控制地飞行,因此字段集/传奇解决方案在IE中无法正常工作。
Therefore, I will like to know if you have any ideas on how this could be achieved. 因此,我想知道您是否对如何实现这一目标有任何想法。
I thought about just setting them frames and the text as part of my background, but as I scale my browser window up and down, everything will look very messy. 我考虑过仅将框架和文本设置为背景的一部分,但是当我上下缩放浏览器窗口时,所有内容看起来都很混乱。
Looking forward to hear your ideas. 期待听到您的想法。 Thank you in advance and have a great day. 在此先感谢您,祝您生活愉快。
Like to sketch-up example of what I would like my frame to looklike 想勾勒出我希望框架看起来像的例子
Try this Demo Here 在这里 尝试这个 演示
<div class="outerDiv">
<div class="innerDiv">Example text here</div>
</div>
.outerDiv{ height: 300px; width: 140px; border-radius: 10px; border:2px solid green; margin: 0 auto; position: relative }
.innerDiv{
color: green;
font-size: 15px;
left: -65px;
position: absolute;
top: 54px;
-webkit-transform: rotate(-90deg);
-moz-transform: rotate(-90deg);
-ms-transform: rotate(-90deg);
-o-transform: rotate(-90deg);
filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=3);
}
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.