11 2017 档案
摘要:1.定义函数的两种方法: a() function a() { console.log("s") }; a() var a=function (){ console.log("123"); } // Uncaught TypeError: a is not a function at 2. 递归 3
阅读全文
摘要:load(url,[data],callback) 载入远程 HTML 文件代码并插入至 DOM 中。 url:待装入 HTML 网页网址。 data:发送至服务器的 key/value 数据。在jQuery 1.3中也可以接受一个字符串了。 callback:载入成功时回调函数。 PHP方面必须是
阅读全文
摘要:1.PHP+JQ+HTML HTML PHP JQ 输出效果: 限制: 1.PHP返回的只能是HTML片段,(json返回不行哦) 2.(“#id”).load 会替换ID中的内容类似 innerHTML="",而不是innerHTML+="";
阅读全文
摘要:(1)text/plain 服务器端: header('Content-Type: text/plain'); echo 'succ'; 客户端: if(xhr.responseText 'succ'){ ... } (2)text/html 服务器端: header('Content-Type:
阅读全文

浙公网安备 33010602011771号