首页 > Web开发 > 详细

css抖动(想怎么抖就怎么抖)很好玩哦

时间:2015-03-26 09:17:30      阅读:233      评论:0      收藏:0      [点我收藏+]

其实要想做抖动不难,最关键的就是会导入外部的css样式就好了。

以下是我编写的代码

<!doctype html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
	<link href="csshake.min.css" type="text/css" rel="stylesheet" />
	<style type="text/css">
      
        h1{color:red;}
        h3{color:#0000ff;}
	</style>
</head>
<body style="text-align:center">

	<h1 class="preview-item big shake shake-hard shake-constant hover-stop">英雄们都给我抖起来 shake</h1>
	<h3 class="shake shake-hard">抖动着的英雄<br />不一样的英雄</h3>
	<div>
		<span class="shake shake-opacity"><img src="2.jpg" height="200" width="400" /></span>
		<span class="shake shale-slow"><img src="4.jpg" height="200" width="400" /></span>
	</div>
	<div>
		<span class="glass shake shake-hard freez"><img src="5.jpg" height="200" width="400" /></span>
	</div>
	<p></p>
	<p class="shake shake-slow">点哪抖哪</p>
	<p>更多详情请点击 <a href="http://blog.csdn.net/qq_24928451 "style="text-decoration:none" target="_blank">csdn</a></p>	
	<p>想要整个网页都一起抖动吗<a href="2.html" style="text-decoration:none" target="_blank">点这里吧!</a></p>
</span>
</body>
</html>


<!doctype html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
	<link href="csshake.min.css" type="text/css" rel="stylesheet" />
	<style type="text/css">
      
        h1{color:red;}
        h3{color:#0000ff;}
        body{text-align:center}
	</style>
</head>
<body class="preview-item big shake shake-hard shake-constant hover-stop">

	<h1 >英雄们都给我抖起来 shake</h1>
	<h3 >抖动着的英雄<br />不一样的英雄</h3>
	<div>
		<span ><img src="2.jpg" height="200" width="400" /></span>
		<span ><img src="4.jpg" height="200" width="400" /></span>
	</div>
	<div>
		<span ><img src="5.jpg" height="200" width="400" /></span>
	</div>
	<p></p>
	<p >点哪抖哪</p>
	<p>更多详情请点击 <a href="http://blog.csdn.net/qq_24928451 "style="text-decoration:none" target="_blank">csdn</a></p>	
</span>
</body>
</html>

技术分享


效果图差不多这样

当你们用时,记得要把图片地址改一下!

http://elrumordelaluz.github.io/csshake/css/csshake.min.css   这是css样式下载表的地址,要用时要下载,直接另存为就可以了。记得要把css样式表和网页放在一起,图片也要放到一起。

技术分享

最好像我这样建个文件夹。

css抖动(想怎么抖就怎么抖)很好玩哦

原文:http://blog.csdn.net/qq_24928451/article/details/44627601

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!