网页设计如何在背景图片上编辑文字
导读:本文共396.5字符,通常情况下阅读需要1分钟。同时您也可以点击右侧朗读,来听本文内容。按键盘←(左) →(右) 方向键可以翻页。
摘要:第一种、将背景图写在css中<style>.class{background: url("图片路径") no-repeat;}</style>接着就直接在html中写文字内容。第二种、写在html中<div class="screen"><div class="img"><img s... ...
目录
(为您整理了一些要点),点击可以直达。第一种、将背景图写在css中<style>.class{background: url("图片路径") no-repeat;}</style>接着就直接在html中写文字内容。第二种、写在html中<div class="screen"><div class="img"><img src="images/logo.png" alt=""></div><div class="intro intro--shown"><p>你的文字内容</p></div></div>css样式,.screen {position: relative;width: 1280px;height: 720px;overflow: hidden;}接着就是包裹的两个div,图片和文字.img {width: 100%;height: 100%;overflow: hidden;border-radius: 7px;position: absolute;}.intro {position: absolute;width: 100%;bottom: -5px;z-index: 20;}z-index: 20;就是可以将文字锁定在你图片的上方
网页设计如何在背景图片上编辑文字的详细内容,希望对您有所帮助,信息来源于网络。