/* -------------------------------- ** FUNCTION: ** fnReverseOrderArray ** DESCRIPTION: ** This function reverses the order of all the ** elements of an array and returns the result ** as a new array reference. ** DEPENDENCIES: ** none. ** DATE: ** -------------------------------- */ function fnReverseOrderArray(aaArray) { var aaReturn = new Array(); //-- Validate function parameters if (aaArray == null) { //-->-->-->-->-->-->-->-->-->-->-->--> //-- Explode some error process //-- return -1; } //-- if array null var jj = 0; for (var ii = aaArray.length - 1; ii > -1; ii--) { aaReturn[jj] = aaArray[ii]; jj++; } return aaReturn; } //-- fnReverseOrderArray