duoroumanggou 2021-08-26 15:43 采纳率: 66.7%
浏览 35
已结题

请问有什么办法能在我的这个代码里把文字设置成不透明吗


<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>作业2</title>
    <link rel="stylesheet" href="style.css">
</head>
<body>
        <div class="header w">
            <div class="logo">
                 <img src="千库.png" alt="">
            </div>
            <div class="nav">
                <ul>
                    <li><a href="#">网站首页</a></li>
                    <li><a href="#">关于我们</a></li>
                    <li><a href="#">新闻中心</a></li>
                    <li><a href="#">产品中心</a></li>
                    <li><a href="#">联系我们</a></li>
                </ul>
            </div>
        </div>
        <div class="banner">
            <div class="w">
                <div class="subnav">
                    <ul>
                        <li><a href="#"> <span class="subnav"> </span></a></li>
                    </ul>
                </div>
                <div class="fr">
                    <ul> 
                        <li>学海<span style="color: orangered;">无涯</span></li>
                        <hr></hr>
                        <p>QIANKU</p>
                        <p1>你要的教材这里都有</p1>
                    </ul>
                </div>
                <div class="fl">
                    <ul>
                        <li><a href="#"> <span class="fl"> </span></a></li>
                    </ul>
                </div>
            </div>
        </div>
</body>
</html>

* {
    margin: 0;
    padding: 0;
}
.w {
    width: 2000px;
    margin: auto;
}
body {
    background-color:transparent;
}
li {
    list-style: none;
}
a {
    text-decoration: none;
}
.clearfix:before,.clearfix:after {
    content:"";
    display:table; 
}
.clearfix:after {
    clear:both;
}
.clearfix {
     *zoom:1;
}
.header{
    height: 90px;
    margin: auto;
    background:black;
    opacity: 0.4;
}
.logo{
    float:left;
    weight:47px;
    height: 90px;
    padding-top: 20px;
    margin-left: 200px;
}
.nav{
    float:left;
    margin-left: 204px;
}
.nav ul li{
    float:left;
    margin: 0 45px;
}
.nav ul li a {
    display: block;
    height: 90px;
    padding: 0px;
    line-height: 90px;
    font-size: 18px;
    color: white;   
}
.nav ul li a:hover {
    border-bottom: 2px solid #ff812a;
    color: #ff812a;
}
.banner {
    clear:both;
    height: 688px;
    background-color:transparent;
}
.banner .w {
    height: 688px;
    background: url(4573.png) no-repeat top center;
    background-size: cover;
}
.subnav {
    float: left;
    width: 100px;
    height: 688px;
    display :inline-block;
    position: relative;
    background-color:transparent;
}
.subnav::after {
    display: inline-block;
    content: " ";
    height: 45px;
    width: 50px;
    border-width: 3px 3px 0 0;
    border-color: white;
    border-style: solid;
    transform: matrix(-0.71, -0.71, 0.71, -0.71, 0, 0);
    position: absolute;
    top: 48%;
    left: 25px;
}
.fr{
    float: left;
    width:935px;
    height: 359px;
    background:black;
    opacity: 0.3;
    margin: 157px 230px auto;
    font-weight: bold;
 }
.fr ul li {
    width:935px;
    height:166px;
    line-height: 166px;
    margin-left: 240px;
    margin-top: 20px;
    font-size: 120px;
    color: white;
}
.fr ul p {
    width:935px;
    height:5px;
    line-height: 5px;
    margin-left: 425px;
    margin-top: 30px;
    font-size: 35px;
    color: white;
}
.fr ul hr {
    width:933px;
    height:5px;
    line-height: 5px;
    margin-left: 0px;
    margin-top: 30px;
    font-size: 35px;
    color: white;
}
.fr ul p1 {
    width:935px;
    height:100px;
    line-height: 100px;
    margin-left: 350px;
    margin-top: 400px;
    font-size: 35px;
    color: white;
}
.fl {
    float: left;
    display :inline-block;
    position: relative;
    width: 490px;
    height: 688px;
    background-color:transparent;
}
.fl::after {
    display: inline-block;
    content: " ";
    height: 45px;
    width: 50px;
    border-width: 3px 3px 0 0;
    border-color: white;
    border-style: solid;
    transform: matrix(0.71, 0.71, -0.71, 0.71, 0, 0);
    position: absolute;
    top: 48%;
    left: 250px;
}

  • 写回答

2条回答 默认 最新

  • Proud lion 2021-08-26 17:08
    关注

    img
    哪里黑盒子

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

问题事件

  • 系统已结题 9月6日
  • 已采纳回答 8月29日
  • 创建了问题 8月26日

悬赏问题

  • ¥50 用易语言http 访问不了网页
  • ¥50 safari浏览器fetch提交数据后数据丢失问题
  • ¥15 matlab不知道怎么改,求解答!!
  • ¥15 永磁直线电机的电流环pi调不出来
  • ¥15 用stata实现聚类的代码
  • ¥15 请问paddlehub能支持移动端开发吗?在Android studio上该如何部署?
  • ¥20 docker里部署springboot项目,访问不到扬声器
  • ¥15 netty整合springboot之后自动重连失效
  • ¥15 悬赏!微信开发者工具报错,求帮改
  • ¥20 wireshark抓不到vlan