jquery随记(效果)----处理多组元素并发(不用特意处理 就是并发)
2011-08-23 10:43
246 查看
<!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 http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档</title>
<link rel="stylesheet" type="text/css" href="Untitled-2.css" />
<script type="text/javascript" src="jquery-1.6.2.js"></script>
<script type="text/javascript">
$(document).ready(function(){
$('p:eq(2)').css('border','1px solid red')
.css('cursor','pointer')
.click(function(){
$(this).slideUp('slow')
.next().slideDown('slow');
});
$('p:eq(3)').css('background-color','#ccc').hide();
});
</script>
</head>
<body>
<div id="switcher" style="border:1px solid red">
<div class="label">Text Size </div>
<button id="switcher-default">Default</button>
<button id="switcher-larger">Bigger</button>
<button id="switcher-small">Small</button>
</div>
<div class="speech">
<p class="p1">Fourscore and seven years ago our fathers brought forth
on this sontinent a new nation,conceived in liberity,
and dedicated to the proposition that all men are created
equal.
</p>
<p>Now we are engaged in a great civil war,testing whether
that nation, or any nation so conceived and so didicated,
can long endure,We are met on a great battlefield of
that war, We have come to dedicate a portion of that
field as a final resting-place for those who here gave
their lives that the nation might live,it is altogether
fitting and proper that we should do this .But,in a larger
sense,we cannot dedicate,we cannont consecrate,
we cannot ballow,this ground.
</p>
<a href="#" class="more">read more</a>
<p>The brave men,living and dead,who struggled
here have consecrated it,far above our poor
power to add or detract,The world will little
note,nor long remember,what we say here,but it
can never forget what they did here.it is for us
the living,rather,to be dedicated here to the
unfinished work which they who fought here have
thus far so nobly advanced
</p>
<p>It is rather for us to be here dedicated to the
great task remaining before us-that from
these honored dead we take increased devotion to
that cause for which they gave the last full
measure of devotion-that we here highly
resolve that these dead shall not have died in
vain-that this nation,under God,shall
have a new birth of freedom and that government
of the people,by the people,for the people,
shall not perish from the earth.
</p>
</div>
</body>
</html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档</title>
<link rel="stylesheet" type="text/css" href="Untitled-2.css" />
<script type="text/javascript" src="jquery-1.6.2.js"></script>
<script type="text/javascript">
$(document).ready(function(){
$('p:eq(2)').css('border','1px solid red')
.css('cursor','pointer')
.click(function(){
$(this).slideUp('slow')
.next().slideDown('slow');
});
$('p:eq(3)').css('background-color','#ccc').hide();
});
</script>
</head>
<body>
<div id="switcher" style="border:1px solid red">
<div class="label">Text Size </div>
<button id="switcher-default">Default</button>
<button id="switcher-larger">Bigger</button>
<button id="switcher-small">Small</button>
</div>
<div class="speech">
<p class="p1">Fourscore and seven years ago our fathers brought forth
on this sontinent a new nation,conceived in liberity,
and dedicated to the proposition that all men are created
equal.
</p>
<p>Now we are engaged in a great civil war,testing whether
that nation, or any nation so conceived and so didicated,
can long endure,We are met on a great battlefield of
that war, We have come to dedicate a portion of that
field as a final resting-place for those who here gave
their lives that the nation might live,it is altogether
fitting and proper that we should do this .But,in a larger
sense,we cannot dedicate,we cannont consecrate,
we cannot ballow,this ground.
</p>
<a href="#" class="more">read more</a>
<p>The brave men,living and dead,who struggled
here have consecrated it,far above our poor
power to add or detract,The world will little
note,nor long remember,what we say here,but it
can never forget what they did here.it is for us
the living,rather,to be dedicated here to the
unfinished work which they who fought here have
thus far so nobly advanced
</p>
<p>It is rather for us to be here dedicated to the
great task remaining before us-that from
these honored dead we take increased devotion to
that cause for which they gave the last full
measure of devotion-that we here highly
resolve that these dead shall not have died in
vain-that this nation,under God,shall
have a new birth of freedom and that government
of the people,by the people,for the people,
shall not perish from the earth.
</p>
</div>
</body>
</html>
相关文章推荐
- 原生Js与jquery的多组处理, 仅展开一个区块的折叠效果
- 原生Js与jquery的多组处理, 仅展开一个区块的折叠效果
- jquery随记(效果)---并发与排队效果(处理一组元素)2011.08.23
- jQuery--元素抖动效果的简单实现
- jquery 实现 鼠标拖拽元素复制并写入效果
- 扩展Jquery插件处理mouseover时内部有子元素时发生样式闪烁
- Ajax或JS动态添加的元素,Jquery效果不起作用
- jQuery获取元素位置以及高度与宽度 动态调整打开新窗口效果
- [jQuery编程挑战]001:实现页面元素加速动画效果
- 使用Jquery随机删除一个顺序列表中某个子元素的方法,保持效果统一性
- Jquery中的事件处理(自动触发事件,禁用按钮,悬停,失焦,滑动效果)
- jquery 实现重复点击一个元素时不重复执行效果
- jQuery学习笔记(三) 元素处理
- 20 个用于处理页面滚动效果的 jQuery 插件
- jQuery碎语(1) 基础、选择要操作的元素、处理DOM元素
- jquery(4-5) val()处理表单元素值
- jQuery简单实现页面元素置顶时悬浮效果示例
- jQuery - 综合实例 - Pre标签在IE与Firefox下效果相对理想的换行处理
- jquery之处理表单元素值(使用val()方法)
- 不用jQuery实现的动画效果代码