Home  >  Article  >  Web Front-end  >  怎样把一个DIV放到另一个div右下角_html/css_WEB-ITnose

怎样把一个DIV放到另一个div右下角_html/css_WEB-ITnose

WBOY
WBOYOriginal
2016-06-24 11:26:092044browse

怎样把一个DIV放到另一个div右下角???

 

借助CSS定位来实现,你将右下角的那个DIV放在另一个DIV里面,参考代码如下示:

测试内容

 

父对象相对定位,子对象以父对象为参考点绝对定位;

外层的div设置为相对定位,内层的div设置为绝对定位;

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn