【Bootstrap】Bootsrap v5 footer页尾

这段代码展示了一个全宽且无下划线的页脚设计,使用了Bootstrap框架。页脚包含三列,分别是关于作者、相关参考和特别致谢的链接。通过.container-fluid确保页脚100%占据屏幕,并通过CSS移除了a标签的下划线及其悬停状态。
摘要由CSDN通过智能技术生成

一、效果

在这里插入图片描述

二、代码

    <style>
        a {
            text-decoration: none !important; 
        }

        a:hover {
            text-decoration: none !important;
        }
    </style>
    
    <div class="container-fluid">
        <footer style="width: 100%; overflow: hidden;">
            <hr style="border: 1px  solid #000000;">
            <div class="row" style="text-align: center;">
                <div class="col-sm-4 col-md-4 col-lg-4">
                    <a href="#" style=" color: gray;">关于作者</a>
                </div>
                <div class="col-sm-4 col-md-4 col-lg-4">
                    <a href="#" style=" color: gray;">相关参考</a></li>
                </div>
                <div class="col-sm-4 col-md-4 col-lg-4">
                    <a href="#" style=" color: gray;">特别致谢</a></li>
                </div>
            </div>
        </footer>
    </div>
    
    <script type="text/javascript" src="/static/js/bootstrap/bootstrap.js"></script>
    <link rel="stylesheet" href="/static/css/bootstrap/bootstrap.css">

三、核心设计

3.1 使页尾100%占据屏幕

 <div class="container-fluid"></div>

.container 类用于固定宽度并支持响应式布局的容器。
.container-fluid 类用于 100% 宽度,占据全部视口(viewport)的容器。

3.1 去除 a 标签下划线

    <style>
        a {
            text-decoration: none !important; 
        }

        a:hover {
            text-decoration: none !important;
        }
    </style>
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

微雨停了

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值