会员可以在此提问,百战程序员老师有问必答
对大家有帮助的问答会被标记为“推荐”
看完课程过来浏览一下别人提的问题,会帮你学得更全面
截止目前,同学们一共提了 134110个问题
JAVA 全系列/第十阶段:权限控制与安全认证/Shiro(旧) 36721楼
Python全系列/第一阶段:AI驱动的Python编程/函数和内存分析 36722楼
JAVA 全系列/第七阶段:项目管理与SSM框架/Mybatis 36723楼

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <style>
        .box1{
            width: 100%;
            height: 50px;
            background-color: blue;
        }
        .wrap{
            width: 700px;
            height: 50px;
            margin: 0 auto;
            background-color: cadetblue;
            padding-top: 10px;
        }
        .box2{
            width: 700px;
            height: 100px;
            background-color: cadetblue;
            margin: 10px auto 0px auto;
            padding-top: 20px;
        }
        .box3{
            width: 700px;
            height: 20px;
            background-color: gray;
            margin: 0 auto;
        }
        .box4{
            width: 700px;
            height: 40px;
            background-color: green;
            margin: 0 auto;
            padding-top: 50px;

        }
        .box5{
            width: 700px;
            height: 250px;
            background-color: gray;
            margin: 0 auto;
            margin-top:40px;

        }
        .box6{
            width: 700px;
            height: 20px;
            background-color: dodgerblue;
            margin: 10px auto 0px auto;
        }
        .num1{
            padding-left: 50%;
            padding-right: 50%;
        }
        .num2{
            padding-left: 50%;
            padding-right: 50%;
        }
        .num3{
            padding-left: 50%;
            padding-right: 50%;
        }
    </style>
</head>
<body>
<div class="box1">
    <div class="wrap"><span class="num1">top1</span></div>
</div>

<div class="box2" ><span class="num2">middle1</span></div>
<div class="box3"></div>
<div class="box4" ><span class="num3">middle2</span></div>
<div class="box5"></div>
<div class="box6"></div>
</body>
</html>

blob.png我写出来效果不对哎

WEB前端全系列/第一阶段:HTML5+CSS3模块/初识CSS 36724楼
JAVA 全系列/第六阶段:JavaWeb开发/Servlet技术详解(旧) 36725楼
Python全系列/第二阶段:Python 深入与提高/文件处理 36726楼
JAVA 全系列/第十一阶段:分布式RPC调用和分布式文件存储/Dubbo 36727楼
Python全系列/第十九阶段:数据分析-数据可视化/matplotlib 36728楼

DOM实操_瀑布流.zip

核对了几遍代码不知道错哪里了image.png

WEB前端全系列/第二阶段:JavaScript编程模块/DOM模型 36729楼
JAVA 全系列/第一阶段:AI驱动的JAVA编程/变量、数据类型、运算符 36730楼
JAVA 全系列/第九阶段:Spring Boot实战/Spring Boot 36731楼
JAVA 全系列/第六阶段:JavaWeb开发/Web实战案例 36732楼
Python全系列/第十二阶段:Python_Django3框架/Django初级 36733楼

<!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>Document</title>

    <style>

        .box {

            width: 100%;

            height: 50px;

            background-color: gray;

        }


        .nav {

            width: 80%;

            height: 50px;

            margin: 0 auto;

            line-height: 50px;

        }


        .nav ul li {

            list-style: none;

            float: left;

            padding: 0 30px;

        }


        .nav ul li a {

            text-decoration: none;

            font-size: 20px;

            color: red;

        }

    </style>

    <style>

        @media screen and(max-width:916px) {

            .liu {

                display: none;

            }

        }


        @media screen and(min-width:916px) {

            .liu {

                display: block;

            }

        }

    </style>

</head>


<body>

    <div class="box">

        <div class="nav">

            <ul>

                <li><a href="#">首页1</a></li>

            </ul>

            <ul>

                <li><a href="#">首页2</a></li>

            </ul>

            <ul>

                <li><a href="#">首页3</a></li>

            </ul>

            <ul>

                <li><a href="#">首页4</a></li>

            </ul>

            <ul>

                <li class="wu"><a href="#">首页5</a></li>

            </ul>

            <ul>

                <li class="liu"><a href="#">首页6</a></li>

            </ul>

        </div>


    </div>

</body>


</html>

能这样隐藏其中一个li标签吗?

WEB前端全系列/第一阶段:HTML5+CSS3模块/CSS3新特性 36734楼

课程分类

百战程序员微信公众号

百战程序员微信小程序

©2014-2025百战汇智(北京)科技有限公司 All Rights Reserved 北京亦庄经济开发区科创十四街 赛蒂国际工业园
网站维护:百战汇智(北京)科技有限公司
京公网安备 11011402011233号    京ICP备18060230号-3    营业执照    经营许可证:京B2-20212637