js實(shí)現(xiàn)仿百度汽車(chē)頻道選擇汽車(chē)圖片展示實(shí)例
本文實(shí)例講述了js實(shí)現(xiàn)仿百度汽車(chē)頻道選擇汽車(chē)圖片展示的方法。分享給大家供大家參考。具體實(shí)現(xiàn)方法如下:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
<title>讓懂車(chē)的人幫你選車(chē)</title>
<style type="text/css" >
*{margin:0;padding:0;}
body{font-family:\5B8B\4F53,Tahoma,Arial Narrow,arial,serif;font-size:12px;color:#000;line-height:1.5em;background:#fff;padding-top:100px;}
a:link,a:visited,a:hover,a:active{color:#fff;text-decoration:none;}
.main{margin:0 auto;width:978px;height:165px;border:1px #DFE5E7 solid;text-align:center;background:url(http://xuanche.baidu.com/static/cms/images/banner.jpg) no-repeat center;position:relative;}
.single{position:absolute;}
.single a{width:100%;height:100%;display:none;position:absolute;left:-3px;}
.single a span{position:absolute;bottom:-20px;left:0;width:100%;height:20px;line-height:20px;background:#AE0D00;color:#fff;text-align:center;display:block;border:3px #AE0D00 solid;box-shadow:3px 2px 3px #A0A0A0;}
.show{border:3px #AE0D00 solid;cursor:pointer;box-shadow:3px 2px 3px #A0A0A0;}
.show a{display:block;z-index:99;}
.caraa{left:5px;top:4px;width:203px;height:151px;}
.carbb{left:209px;top:4px;width:101px;height:101px;}
.carcc{left:260px;top:106px;width:101px;height:50px;}
.cardd{left:362px;top:4px;width:101px;height:50px;}
.caree{left:362px;bottom:3px;width:152px;height:102px;}
.carff{left:515px;top:4px;width:101px;height:101px;}
.cargg{left:515px;bottom:3px;width:101px;height:50px;}
.carhh{left:719px;top:4px;width:101px;height:50px;}
.carii{left:821px;top:4px;width:145px;height:102px;}
.carjj{left:872px;bottom:3px;width:94px;height:50px;}
.maintext{position:absolute;width:50px;height:50px;line-height:50px;text-align:center;z-index:1;}
.maintext p{font-family:"微軟雅黑";font-size:19px;font-weight:bold;color:#BBBFC1;}
.maintext p span{font-size:14px;}
.fuel{left:312px;top:58px;}
.power{left:620px;top:7px;}
.control{left:824px;top:109px;}
.include{position:absolute;left:620px;top:58px;width:203px;height:80px;padding-top:20px;}
.include p{font-size:14px;font-family:"微軟雅黑";font-weight:bold;color:#BBBFC1;line-height:30px;}
.include p span{font-size:18px;font-family:Arial,Tahoma,sans-serif;color:#fff;}
</style>
</head>
<body>
<!--主體開(kāi)始-->
<div class="main">
<!--起亞開(kāi)始-->
<div class="single caraa" onmouseover="this.className='single caraa show'" onmouseout="this.className='single caraa'" >
<a href="#" target="_blank" >
<span>起亞K5</span>
</a>
</div>
<!--起亞結(jié)束-->
<!--英郎開(kāi)始-->
<div class="single carbb" onmouseover="this.className='single carbb show'" onmouseout="this.className='single carbb'" >
<a href="#" target="_blank" >
<span>英郎</span>
</a>
</div>
<!--英郎結(jié)束-->
<!--捷達(dá)開(kāi)始-->
<div class="single carcc" onmouseover="this.className='single carcc show'" onmouseout="this.className='single carcc'" >
<a href="#" target="_blank" >
<span>捷達(dá)</span>
</a>
</div>
<!--捷達(dá)結(jié)束-->
<!--POLO開(kāi)始-->
<div class="single cardd" onmouseover="this.className='single cardd show'" onmouseout="this.className='single cardd'" >
<a href="#" target="_blank" >
<span>POLO</span>
</a>
</div>
<!--POLO結(jié)束-->
<!--途觀開(kāi)始-->
<div class="single caree" onmouseover="this.className='single caree show'" onmouseout="this.className='single caree'" >
<a href="#" target="_blank" >
<span>途觀</span>
</a>
</div>
<!--途觀結(jié)束-->
<!--科魯茲開(kāi)始-->
<div class="single carff" onmouseover="this.className='single carff show'" onmouseout="this.className='single carff'" >
<a href="#" target="_blank" >
<span>科魯茲</span>
</a>
</div>
<!--科魯茲結(jié)束-->
<!--朗逸開(kāi)始-->
<div class="single cargg" onmouseover="this.className='single cargg show'" onmouseout="this.className='single cargg'" >
<a href="#" target="_blank" >
<span>朗逸</span>
</a>
</div>
<!--朗逸結(jié)束-->
<!--速騰開(kāi)始-->
<div class="single carhh" onmouseover="this.className='single carhh show'" onmouseout="this.className='single carhh'" >
<a href="#" target="_blank" >
<span>速騰</span>
</a>
</div>
<!--速騰結(jié)束-->
<!--寶來(lái)開(kāi)始-->
<div class="single carii" onmouseover="this.className='single carii show'" onmouseout="this.className='single carii'" >
<a href="#" target="_blank" >
<span>寶來(lái)</span>
</a>
</div>
<!--寶來(lái)結(jié)束-->
<!--??怂归_(kāi)始-->
<div class="single carjj" onmouseover="this.className='single carjj show'" onmouseout="this.className='single carjj'" >
<a href="#" target="_blank" >
<span>??怂?lt;/span>
</a>
</div>
<!--??怂菇Y(jié)束-->
<div class="maintext fuel">
<p>省<span>油</span></p>
</div>
<div class="maintext power">
<p>動(dòng)<span>力</span></p>
</div>
<div class="maintext control">
<p>操<span>控</span></p>
</div>
<div class="include">
<p>共收錄<span>389</span>款汽車(chē)</p>
<p>已有<span>3499</span>名車(chē)主點(diǎn)評(píng)</p>
</div>
</div>
<!--主體結(jié)束-->
</body>
</html>
希望本文所述對(duì)大家的javascript程序設(shè)計(jì)有所幫助。
- javascript實(shí)現(xiàn) 百度翻譯 可折疊的分享按鈕列表
- js實(shí)現(xiàn)分享到隨頁(yè)面滾動(dòng)而滑動(dòng)效果的方法
- JS實(shí)現(xiàn)仿google、百度搜索框輸入信息智能提示的實(shí)現(xiàn)方法
- js實(shí)現(xiàn)仿百度瀑布流的方法
- JS仿百度搜索自動(dòng)提示框匹配查詢(xún)功能
- 仿百度輸入框智能提示的js代碼
- 利用JS延遲加載百度分享代碼,提高網(wǎng)頁(yè)速度
- 百度地圖api應(yīng)用標(biāo)注地理位置信息(js版)
- javascript實(shí)現(xiàn)類(lèi)似百度分享功能的方法
相關(guān)文章
JavaScript中toLocaleString()和toString()的區(qū)別實(shí)例分析
這篇文章主要介紹了JavaScript中toLocaleString()和toString()的區(qū)別,結(jié)合實(shí)例形式對(duì)比分析了toLocaleString()和toString()針對(duì)字符串、數(shù)組與日期操作過(guò)程中的區(qū)別與使用技巧,需要的朋友可以參考下2018-08-08
使用BootStrap實(shí)現(xiàn)懸浮窗口的效果
本文給大家分享使用BootStrap實(shí)現(xiàn)懸浮窗口的效果,神奇的 bootstrap就自帶了這個(gè)功能。所以就用bootstrap的popover插件做了,效果還不錯(cuò),感興趣的朋友參考下吧2016-12-12
談?wù)別ncodeURI和encodeURIComponent以及escape的區(qū)別與應(yīng)用
encodeURI和encodeURIComponent以及escape,這三個(gè)都是用來(lái)編碼的,本篇文章給大家介紹encodeURI和encodeURIComponent以及escape的區(qū)別與應(yīng)用,感興趣的朋友一起學(xué)習(xí)吧2015-11-11
JavaScript之移動(dòng)端H5生成圖片解決方案講解
這篇文章主要介紹了JavaScript之移動(dòng)端H5生成圖片解決方案講解,本篇文章通過(guò)簡(jiǎn)要的案例,講解了該項(xiàng)技術(shù)的了解與使用,以下就是詳細(xì)內(nèi)容,需要的朋友可以參考下2021-08-08
根據(jù)當(dāng)前時(shí)間在jsp頁(yè)面上顯示上午或下午
這篇文章主要介紹了根據(jù)當(dāng)前時(shí)間不同在jsp頁(yè)面上顯示上午或下午,需要的朋友可以參考下2014-08-08
JavaScript canvas實(shí)現(xiàn)跟隨鼠標(biāo)事件
這篇文章主要為大家詳細(xì)介紹了JavaScript canvas實(shí)現(xiàn)跟隨鼠標(biāo)事件,文中示例代碼介紹的非常詳細(xì),具有一定的參考價(jià)值,感興趣的小伙伴們可以參考一下2020-02-02
js apply/call/caller/callee/bind使用方法與區(qū)別分析
js apply/call/caller/callee/bind使用方法與區(qū)別分析,需要的朋友可以參考下。2009-10-10

