$("div>label,p>label,p").css("border", "solid 5px red");
这样。
这样。
2015-07-24
1.对div做一个click的绑定事件(对div进行单击)
i.单击就移除其backcolor样式,再增加color样式
ii.绑定一个dblclick事件(对div进行双击)
移除color样式,增加backcolor样式
2.对按钮button做一个单击click的绑定事件
i.对div移除其dblclick事件
ii.设置按钮本身为不可用
i.单击就移除其backcolor样式,再增加color样式
ii.绑定一个dblclick事件(对div进行双击)
移除color样式,增加backcolor样式
2.对按钮button做一个单击click的绑定事件
i.对div移除其dblclick事件
ii.设置按钮本身为不可用
2015-07-24
$(".red,.green").html("hi,我们的样子很美哦!");
2015-07-24
$(document).ready(function() {
var $json = {"Mike":"100", "John":"89","Tim":"44"}
$("#btn").bind("click",function() {
$.each($json,function(key,value) {
$("#result").append(key+"----"+value+"<br>");
var $json = {"Mike":"100", "John":"89","Tim":"44"}
$("#btn").bind("click",function() {
$.each($json,function(key,value) {
$("#result").append(key+"----"+value+"<br>");
<script type="text/javascript">
function toggle(){
var $htmlaText = $("a").html();
if($htmlaText == '更多'){
$("li:gt(3)").show();
$("a").html("简化");
}else{
$("a").html("更多");
$("li:gt(3):not(:last)").hide();
}
};
</script>
function toggle(){
var $htmlaText = $("a").html();
if($htmlaText == '更多'){
$("li:gt(3)").show();
$("a").html("简化");
}else{
$("a").html("更多");
$("li:gt(3):not(:last)").hide();
}
};
</script>