2015年11月2日
Ajax
push() 方法可向数组的末尾添加一个或多个元素,并返回新的长度。
var arr = new Array(3)
arr[0] = "George"
arr[1] = "John"
arr[2] = "Thomas"
document.write(arr + "<br />")
document.write(arr.push("James") + "<br />")
document.write(arr)
//输出
George,John,Thomas
4
George,John,Thomas,Jamesjoin() 方法用于把数组中的所有元素放入一个字符串。 元素是通过指定的分隔符进行分隔的。
var arr = new Array(3)
arr[0] = "George"
arr[1] = "John"
arr[2] = "Thomas"
document.write(arr.join("."))
//输出:
George.John.ThomasAjax的POST请求
Ajax超市设置
Last updated
Was this helpful?