Try
var row = [ 23, "this is a string", true ]; $.each(row, function (index,item) { alert(typeof(item)); });
Whenever possible, I try to avoid using "this" in callbacks, and using explicit arguments is usually clearer and more predictable.
source share