利用html 和css模仿必应搜索主页。(一)

以下为源代码。勿喷!!

 很简单的基本功能实现,运用到css的一些属性,盒子模型  绝对定位等等!

<html xmlns="http://www.w3.org/1999/xhtml">

<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>bing搜索</title>
<style type="text/css">
body{background: #333;}
.lo{background-image: url(背景.jpg);height: 640px;width: 1366px;margin: 0 auto;}
.logo{background-image: url(hee.png);width: 128px;height: 128px;float: left;margin-top:-40px; }
.botton1{height: 35px;width: 190px;float: left;border: 0 ;outline: none; font-size: 25px;background-color: #fff;}
.botton2{background-image: url(搜索.png);height: 46px;width: 45px;float: left;border:0;}/*设置按钮背景图片="搜索.png" 设置高  宽  浮动方向 清除边框样式*/
form{float: left;background-color: #fff;}
.all{position: absolute;top: 350px;left: 500px;}/*相对定位 设置距离上方为350像素 左边为500像素*/
</style>
</head>
<body>
<div class="lo">
<div class="all">
<div class="logo"></div>
<form>
<input type="text" class="botton1"/>
<input type="submit" class="botton2" value=""/>
</form>
</div>
</div>
</body>
</body>

</html>

下面为浏览器打开视图!!




IE打开还是没有什么变化,兼容性一般般


  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值