Side navigation
Ticket #4459: map_test_case.js
File map_test_case.js, 0.3 KB (added by gero_, March 31, 2009 01:19PM UTC)
$(document).ready(function(){
var test_obj = { 0:'zero', 1:'one' };
var test_arr = [ 'zero', 'one' ];
$.map(test_arr, function (n, i) {
alert('I\'m iterating (array)!');
});
$.map(test_obj, function (n, i) {
alert('I\'m iterating (object)!');
});
});
Download in other formats:
Original Format
File map_test_case.js, 0.3 KB (added by gero_, March 31, 2009 01:19PM UTC)
$(document).ready(function(){
var test_obj = { 0:'zero', 1:'one' };
var test_arr = [ 'zero', 'one' ];
$.map(test_arr, function (n, i) {
alert('I\'m iterating (array)!');
});
$.map(test_obj, function (n, i) {
alert('I\'m iterating (object)!');
});
});