html:

$.font($("p"),"30px").html("变化了")

jQuery:

$.extend({
font:function(obj,value){
obj.css("font-size",value)
return obj            //这里要是不返回值得话,会无法实现连缀
}
})

jQuery插件初级练习2答案的更多相关文章

  1. jQuery插件初级练习5答案

    html: $.kafei.fontsize($("p"),"30px").html("123") jQuery: $.kafei={ fo ...

  2. jQuery插件初级练习4答案

    html: $("p").log().css("color","red") jQuery: $.fn.extend({ log: funct ...

  3. jQuery插件初级练习3答案

    html: $("p").fontcolor().html("qaq") jQuery: $.fn.extend({ fontcolor:function(){ ...

  4. jQuery插件初级练习1答案

    html: <script> $(".btn").click(function(){ $.color($("#box"),"blue&qu ...

  5. jQuery插件初级练习1

    <!DOCTYPE html><html> <head> <meta charset="UTF-8"> <title>& ...

  6. jQuery插件初级练习5

    <!DOCTYPE html><html> <head> <meta charset="UTF-8"> <title>& ...

  7. jQuery插件初级练习4

    <!DOCTYPE html><html> <head> <meta charset="UTF-8"> <title>& ...

  8. jQuery插件初级练习3

    <!DOCTYPE html><html> <head> <meta charset="UTF-8"> <title>& ...

  9. jQuery插件初级练习2

    <!DOCTYPE html><html> <head> <meta charset="UTF-8"> <title>& ...

随机推荐

  1. phpstorm的安装和使用

    1下载phpstorm #下载地址 https://www.jetbrains.com/phpstorm/ 2激活并安装 create associations 表示的是以后编辑选择的文件也默认用id ...

  2. POJ 3041.Asteroids 最小顶点覆盖

    Asteroids Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 22905   Accepted: 12421 Descr ...

  3. Django报错:__init__() missing 1 required positional argument: 'on_delete'

    原因: 在django2.0后,定义外键和一对一关系的时候需要加on_delete选项,此参数为了避免两个表里的数据不一致问题,不然会报错:TypeError: __init__() missing ...

  4. 部署描述符(web.xml)和标注(annotation)

    部署描述符(web.xml) 详细信息可在http://www.oracle.com/webfolder/technetwork/jsc/xml/ns/javaee/index.html上下载web- ...

  5. Python 之异常处理机制

    python在程序运行出现错误时时有相应的反应机制 ,我们可以针对不同的错误做出不同的响应 list1 = ['a','b','c'] print(list1[4]) #>>>Ind ...

  6. TP QQ 微信 微博登录

    use Org\Util\QQconnect; use Org\Util\Wechatauth; use Org\Util\SaeTOAuthV2; use Org\Util\SaeTClientV2 ...

  7. Trapping Rain Water LT42

    The above elevation map is represented by array [0,1,0,2,1,0,1,3,2,1,2,1]. In this case, 6 units of ...

  8. 初识jvm堆,栈参数

    堆的分配参数: -Xmx //设立最大堆 -Xms //最小堆,初始化堆大小 -Xmn  //设置新生代(eden+2*surviivor+old)大小   官方推荐:3/8Xmx------> ...

  9. 操作Float的BigDecimal加减乘除

    bignum3 =  bignum1.add(bignum2);     //加 bignum3 = bignum1.subtract(bignum2);  减 bignum3 = bignum1.m ...

  10. 13个开源GIS软件 你了解几个?

    地理信息系统(Geographic Information System,GIS)软件依赖于覆盖整个地球的数据集.为处理大量的 GIS 数据及其格式,编程人员创建了若干开源库和 GIS 套件. GIS ...