javascript stuffs

  1. Primitive types
    1. undefined, null, boolean, number, string; undefined is derived from null.
    e.g. var tmp; typeof tmp == undefined.
    e.g. void(javascript:aler(‘x’)) == undefined.
    e.g. undefined==null
    2. NaN!=NaN isNaN(“123”)==false isNaN(“blue”)==true
    3. var num = 10; num.toString();num.toString(2);num.toString(8);num.toString(16)
  2. 4. parseInt, parseFloat
  3. 5. object class
      1.     properties: constructor, prototype
          1.     methods: hasOwnProperty(property), isPrototypeOf(object), propertyIsEnumberable(property),toString(),valueOf()
  4. 6. 在Boolean表示大中,所有对象都会被自动转换为true
  5. 7. Number class: toFixed, MAX_VALUE, POSITIVE_INFINITE, NEGATIVE_INFINITE, toPrecision, toExponential
  6. 8. String: length, charAt(), concat, indexOf, lastIndexOf, localeCompare, compare, subString, slice, toLowerCase, toLowerCase, toUpperCase, toLocaleUpperCase, split
  7. 9. delete只能删除开发者自定义的方法和属性。
  8. 10. js中的对象的内在表征是key value集合
  9. 11. js不允许overload
  10. 12. 每个函数的调用堆栈中都有一个arguments对象
  11. 13. Function class:var f = new Function(argument1, argument2, …, argumentN, function_body_string)
  12.       e.g. var f = new Function(“n”, “alert(n)”)
  13. 14. 判断时区使用的是否是夏令时
  14.      e.g. d1 = new Date(2008,6,1); d2 = new Date(2008,6,1); support = d1.getTimezonOffset()!=d2.getTimezoneOffset();
  15. 15. undefined, NaN, Infinity, Object, Array, Function, Boolean, String, Number, Date, RegExp, Error, EvalError, ReferenceError, SyntaxError, TypeError, URIError
  16. 16. Math class: E,LN10,LN2,LOG2E,LOG10E,PI,SQRT1_2,SQRT2,min,max,ceil,floor,round,pow,exp,sin,cos,tan,atan,atan2,asin,acos
  17. 17. window.open(uri, [frame_name|top|parent|self|blank],parameter)
    1.       where parameter: left, top, height, width, resizable, scrollable, toolbar, status, location
  18. 18. 最好尽量少弹出窗口,因为有可能被拦截. var win = window.open(…). if (win == null){…}else{…}
  19. 19. history: go(-1), back, forward
  20. 20. document: alinkcolor, bgcolor, fgcolor, lastModified, linkColor, referer, title, URL, vlinkColor, domain, anchors, applets, embeds, forms, images, links
  21. 21. location: hash, host, hostname, href, pathname, port, protocol, search, reload(cache)
  22. 22. navigator: appCodeName, appName, appMinorVersion, appVersion, broserLanguage, cookieEnabled, cpuClass, javaEnabled(), language, mimeTypes, onLin, oscpu, platform, plugins, preference(), product, productSub, opsProfile, securityPolicy, systemLanguage, taintEnabled, userAgent, userLanguage, userProfile, vendor, vendorSub
  23. 23. screen: availHeight, availWidth, colorDepth, heigth, width
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值