摘要: 1.jsonp跨域 jsonp跨域是通过script标签的跨域请求资源的能力,先利用JS在dom中创建一个script,把json里的url地址赋给script的src属性,然后新建一个script把url地址赋给script。 获取数据的方法:通过callback回调函数,把回调函数给cd (&c 阅读全文
posted @ 2016-04-29 16:12 FallenLunatic 阅读(156) 评论(0) 推荐(0) 编辑
摘要: 1.什么是字符串 String类型用于表示零或多个16位的Unicode字符串组成的字符序列,即字符串,字符串可以由双引号(")或单引号(')表示。 转换为字符串 toString() var a = 10; alert(a.toString) String() var a =10; alert(S 阅读全文
posted @ 2016-04-29 12:03 FallenLunatic 阅读(282) 评论(0) 推荐(0) 编辑