基于jQuery CSS3實現鼠標懸停信息提示代碼



39 152 51



特效描述:基于jQuery CSS3實現 鼠標懸停 信息提示,基于jQuery CSS3實現鼠標懸停信息提示代碼

代碼結構

1. 引入CSS

<link rel="stylesheet" href="css/demo.css">
<link rel="stylesheet" href="css/sweet-tooltip.css">

2. 引入JS

<script type="text/javascript" src="js/jquery.min.js"></script>
<script type="text/javascript" src="js/sweet-tooltip.js"></script>

3. HTML代碼

	<div id="container">
		<div class="item-tooltip">
			<div class="item">
				<span class="top-title">Sweet Strong </span>
				<div class="image-item"><img src="images/sweet-strong.png" /></div>
			</div>
			<div class="item-information">
				<span class="title">Style Name </span>
				<span class="information-content">
					tooltip-sweet-strong
				</span>
				<span class="title">Example </span>
				<span class="information-content">
					Hover <a href="#" class="sweet-tooltip" data-style-tooltip="tooltip-sweet-strong" data-text-tooltip="Howdy, I'm your tooltip :) ">this link</a> to see how this tooltip works
				</span>
			</div>
		</div>
		<div class="item-tooltip">
			<div class="item">
				<span class="top-title">Mini Slick </span>
				<div class="image-item"><img src="images/mini-slick.png" /></div>
			</div>
			<div class="item-information">
				<span class="title">Style Name </span>
				<span class="information-content">
					tooltip-mini-slick
				</span>
				<span class="title">Example </span>
				<span class="information-content">
					Hover <a href="#" class="sweet-tooltip" data-style-tooltip="tooltip-mini-slick" data-text-tooltip="Edit Me? ">this link</a> to see how this tooltip works
				</span>
			</div>
		</div>
		<div class="item-tooltip">
			<div class="item">
				<span class="top-title">Big Grey </span>
				<div class="image-item"><img src="images/big-grey.png" /></div>
			</div>
			<div class="item-information">
				<span class="title">Style Name </span>
				<span class="information-content">
					tooltip-big-grey
				</span>
				<span class="title">Example </span>
				<span class="information-content">
					Hover <a href="#" class="sweet-tooltip" data-style-tooltip="tooltip-big-grey" data-text-tooltip="This is our tooltip. <br/> How about yours? ">this link</a> to see how this tooltip works
				</span>
			</div>
		</div>
		<div class="item-tooltip">
			<div class="item">
				<span class="top-title">Nightly </span>
				<div class="image-item"><img src="images/nightly.png" /></div>
			</div>
			<div class="item-information">
				<span class="title">Style Name </span>
				<span class="information-content">
					tooltip-nightly
				</span>
				<span class="title">Example </span>
				<span class="information-content">
					Hover <a href="#" class="sweet-tooltip" data-style-tooltip="tooltip-nightly" data-text-tooltip="Nightly Nightly">this link</a> to see how this tooltip works
				</span>
			</div>
		</div>
		<div class="item-tooltip">
			<div class="item">
				<span class="top-title">Shiny Red </span>
				<div class="image-item"><img src="images/shiny-red.png" /></div>
			</div>
			<div class="item-information">
				<span class="title">Style Name </span>
				<span class="information-content">
					tooltip-shiny-red
				</span>
				<span class="title">Example </span>
				<span class="information-content">
					Hover <a href="#" class="sweet-tooltip" data-style-tooltip="tooltip-shiny-red" data-text-tooltip="This is shiny red">this link</a> to see how this tooltip works
				</span>
			</div>
		</div>
		<div class="item-tooltip">
			<div class="item">
				<span class="top-title">Soft Blue </span>
				<div class="image-item"><img src="images/soft-blue.png" /></div>
			</div>
			<div class="item-information">
				<span class="title">Style Name </span>
				<span class="information-content">
					tooltip-soft-blue
				</span>
				<span class="title">Example </span>
				<span class="information-content">
					Hover <a href="#" class="sweet-tooltip" data-style-tooltip="tooltip-soft-blue" data-text-tooltip="Really soft blue">this link</a> to see how this tooltip works
				</span>
			</div>
		</div>
		<div class="item-tooltip">
			<div class="item">
				<span class="top-title">Big Yellow </span>
				<div class="image-item"><img src="images/big-yellow.png" /></div>
			</div>
			<div class="item-information">
				<span class="title">Style Name </span>
				<span class="information-content">
					tooltip-big-yellow
				</span>
				<span class="title">Example </span>
				<span class="information-content">
					Hover <a href="#" class="sweet-tooltip" data-style-tooltip="tooltip-big-yellow" data-text-tooltip="This is big yellow">this link</a> to see how this tooltip works
				</span>
			</div>
		</div>
	</div>
<div style="text-align:center;clear:both">
</div>



用戶評論
大牛,別默默的看了,快登錄幫我點評一下吧!:)      登錄 | 注冊


熱門標簽: 文字疊加 文字層疊 文字放大縮小 文字縮放 文字大小 文字放大 文字縮小 文字變大 文字變小 文字淡出淡進 文字淡出 文字淡進 文字翻轉 文字旋轉 文字收縮展開 文字收縮 文字展開 文字提示框 提示文字 文字全屏 文字拖動 文字拖拽 文字延遲加載 文字延遲 文字加載 h5文字動畫 h5文字邊框動畫 html5文字動畫 html5文字邊框動畫 360全景 360度全景 文字滑動 文字滑塊 文字滾動 文字無縫滾動 文字間歇滾動 彈出層拖動 文字切換 文字選項卡 窗口 彈出 彈窗 彈出層 提示框 對話框 遮罩 遮罩層 彈窗插件 滑動星星打分 圖片文字 文字導航菜單 文字導航 文字菜單 文字 文字插件 其他 鼠標懸停 文字標簽 文字標簽云 標簽云 文字提示框 提示文字
?
×
×

注冊

官方QQ群

掃描上面二維碼加微信群

官方QQ群

jQuery/js討論群
群號:642649996
Css3+Html5討論群
群號:322131262

加群請備注:從官網了解到

老夫子电子