首页
极刻
圈子
教程
开源
登录 / 注册
返回教程:CSS 教程
TRY RUN / 在线示例
CSS 教程 使用像素值设置图像的底部
CSS 教程 使用像素值设置图像的底部
源代码
运行
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>安科教程(www.ancii.com)</title> <style> img.ex1 { position:absolute; bottom:0px; } img.ex2 { position:relative; bottom:-100px; } </style> </head> <body> <img class="ex1" src="/attachments/cover/cover_css.png" width="95" height="84"> <h1>This is a heading</h1> <img class="ex2" src="/attachments/cover/cover_css.png" width="95" height="84"> </body> </html>
运行结果