为了账号安全,请及时绑定邮箱和手机立即绑定

百度搜索框中的相机?

百度搜索框中的相机?

慕娘5512214 2017-09-22 15:27:59
自己做一个百度的首页,可是搜索框的相机总是加不进去,鼠标指向相机也不会自动变色,求老师帮忙。<!DOCTYPE html><html><head><meta http-equiv="content-type" content="text/html; charset=UTF-8">    <title>一次</title><meta charset="utf-8"><style type="text/css">        .q1{            float: right; width: 50px; text-decoration: underline; font-weight: bold;         }        .q1:hover{            color: blue;        }        .q2{            display: inline-block;width: 18px;height: 16px;            background-image: url(camera_new_5606e8f.png);        }        .q2:hover{            margin-top: -8px;background-repeat: no-repeat;             background-image: url(camera_new_5606e8f.png);            resize: 0 -16px;        }        .q3{            background-color: #436EEE; width: 100px;height: 36px;            border: 0px;color: #fff;        }        .q3:hover{ background-color: #3A5FCD }        .q4{            clear: both;text-align: center;            position: relative;top: 405px;            font-size: 13px;        }        .q5{            clear: both; text-align: center;            position: relative;top: 410px;        }        #w5{        color: #a8a8a8; margin-left:25px; width: 48px;height: 14px;font-size:12px        }        .q6{            clear: both; text-align: center;            position: relative;top: 420px;             color: #a8a8a8;font-size: 12px;        }        #w6{        color: #a8a8a8; margin-left:25px; width: 48px;height: 14px;        }        .q7{            display: inline-block;width: 14px;height: 17px;            background-image: url(01.jpg);        }        .q8{            display: inline-block;width: 14px;height: 17px;            background-image: url(02.jpg);            margin-bottom: -3px;        }        #w1{            width: 70px; background-color: #436eee; color: #fff; text-align: center;        }        #w2{            width: 70px;        }        #div1{            clear: both; text-align: center;        }        #div2{            text-align: center;        }        #div3{            clear: both;text-align: center;            position: relative;top: 420px;        }    </style></head>    <body>    <p class="q1" id="w1">更多产品</p>    <p class="q1">设置</p>    <p class="q1">登录</p>    <p class="q1">学术</p>    <p class="q1">贴吧</p>    <p class="q1">视频</p>    <p class="q1">地图</p>    <p class="q1" id="w2">hao123</p>    <p class="q1">新闻</p>    <div id="div1">        <img src="%E4%B8%80%E6%AC%A1_files/bd_logo.png" width="350px">    </div>        <div id="div2">            <span class="q2"></span>            <input style="width: 456px;height: 30px; margin-right: -5px;" type="text">            <input class="q3" type="submit" value="百度一下">        </div>        <div id="div3"><img src="zbios_efde696.png"></div>        <p class="q4"><b>手机百度</b></p>        <div>        <p class="q5">            <a id="w5" href="baidu">把百度设置为主业</a>            <a id="w5" href="baidu">关于百度</a>            <a id="w5" href="baidu">About Baidu</a>            <a id="w5" href="baidu">百度推广</a>        </p>        <p class="q6">            @2017Baidu            <a id="w6" href="baidu">使用百度前必读</a>            <a id="w6" href="baidu">意见反馈</a>            京ICP证0317号            <span class="q7"></span>            <a id="w6" href="baidu">京工网安备11000002000001号</a>            <span class="q8"></span>        </p>        </div></body></html>
查看完整描述

2 回答

已采纳
?
一诺yinol

TA贡献27条经验 获得超4个赞

贴代码!

查看完整回答
反对 回复 2017-09-22
  • 慕娘5512214
    慕娘5512214
    <span class="q2"></span> .q2{ display: inline-block;width: 18px;height: 16px; background-image: url(camera_new_5606e8f.png); } .q2:hover{ margin-top: -8px;background-repeat: no-repeat; background-image: url(camera_new_5606e8f.png); resize: 0 -16px; }
  • 一诺yinol
    一诺yinol
    你在百度那个页面 F12 你就能直接看到百度是怎么布局了!或者你把代码贴全!
  • 慕娘5512214
    慕娘5512214
    相机是class=“q2”;
?
慕娘5512214

TA贡献2条经验 获得超0个赞

<span class="q2"></span>

.q2{
            display: inline-block;width: 18px;height: 16px;
            background-image: url(camera_new_5606e8f.png);
        }
 .q2:hover{
            margin-top: -8px;background-repeat: no-repeat;
            background-image: url(camera_new_5606e8f.png);
            resize: 0 -16px;
        }

查看完整回答
反对 回复 2017-09-22
  • 2 回答
  • 1 关注
  • 381 浏览
慕课专栏
更多

添加回答

举报

0/150
提交
取消
意见反馈 帮助中心 APP下载
官方微信