[英]How to have a child image be larger then a parent div and be positioned anywhere
I have a parent container div with display: inline-block
. 我有一个带
display: inline-block
的父容器div display: inline-block
。 This allows me to adjust the image height using % values. 这使我可以使用%值来调整图像高度。 I can't adjust the width beyond 100% though which I need.
尽管我需要调整宽度,但不能超过100%。
How in css/html can I setup a parent div
and child image
so that I can use % values to scale the image larger then the parent and position the image top and left with % values? 如何在css / html中设置
parent div
和child image
以便可以使用%值将图像缩放到比父图像更大,并使用%值在图像的顶部和左侧定位?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.