摘要:
HTML:<h3>原始显示</h3><div id="show5"></div><h3>应用grep()方法后(1)</h3><div id="show6"></div><h3>应用grep()方法后(2)</h3><div id="show7"></div>jquery:var animals = ['dog','cat','tiger', 阅读全文
摘要:
HTML:<h3>数组map方法</h3><div id="show4"></div>jquery:$(document).ready(function(){ var animals = ['dog','cat','tiger','pig','bird']; animals = $.map(animals, function(n,i){ return i+'.This is '+n; ... 阅读全文
摘要:
HTML代码:<h3>纵向显示数组</h3><div id="show1"></div><h3>显示数组的键名和键值</h3><div id="show2"></div><h3>利用html元素创建数组并计算长度</h3><div id="show3"></div>Jquery:$(document).ready(function(){ var animals = ['dog' 阅读全文