FOUND THIS SOMEWHERE - not mine...but want to post it for others since I was going crazy trying to find something that would clone multi-dimensional arrays...

keywords: clone, copy, array, multi dimensional


Array.prototype.clone = function () {
var tmp = [];
for (i in this) {
if (this[i].constructor == Array) {
tmp[i] = this[i].clone();
} else {
tmp[i] = this[i];
}
}
return tmp;
}