function _trueTypeOf(something) {
    var result = typeof something;
    try {
        switch (result) {
            case 'string':
            case 'boolean':
            case 'number':
                break;
            case 'object':
            case 'function':
                switch (something.constructor)
                        {
                    case String:
                        result = 'String';
                        break;
                    case Boolean:
                        result = 'Boolean';
                        break;
                    case Number:
                        result = 'Number';
                        break;
                    case Array:
                        result = 'Array';
                        break;
                    case RegExp:
                        result = 'RegExp';
                        break;
                    case Function:
                        result = 'Function';
                        break;
                    default:
                        var m = something.constructor.toString().match(/function\s*([^( ]+)\(/);
                        if (m)
                            result = m[1];
                        else
                            break;
                }
                break;
        }
    }
    finally {
        result = result.substr(0, 1).toUpperCase() + result.substr(1);
        return result;
    }
}
function _trueTypeOf(something) {
    var result = typeof something;
    try {
        switch (result) {
            case 'string':
            case 'boolean':
            case 'number':
                break;
            case 'object':
            case 'function':
                switch (something.constructor)
                        {
                    case String:
                        result = 'String';
                        break;
                    case Boolean:
                        result = 'Boolean';
                        break;
                    case Number:
                        result = 'Number';
                        break;
                    case Array:
                        result = 'Array';
                        break;
                    case RegExp:
                        result = 'RegExp';
                        break;
                    case Function:
                        result = 'Function';
                        break;
                    default:
                        var m = something.constructor.toString().match(/function\s*([^( ]+)\(/);
                        if (m)
                            result = m[1];
                        else
                            break;
                }
                break;
        }
    }
    finally {
        result = result.substr(0, 1).toUpperCase() + result.substr(1);
        return result;
    }
}
function _trueTypeOf ( something ) { var result = typeof something ; try { switch ( result ) { case 'string' : case 'boolean' : case 'number' : break ; case 'object' : case 'function' : switch ( something . constructor ) { case String : result = 'String' ; break ; case Boolean : result = 'Boolean' ; break ; case Number : result = 'Number' ; break ; case Array : result = 'Array' ; break ; case RegExp : result = 'RegExp' ; break ; case Function : result = 'Function' ; break ; default : var m = something . constructor . toString ( ) . match ( / function\s*([^( ]+)\( / ) ; if ( m ) result = m [ 1 ] ; else break ; } break ; } } finally { result = result . substr ( 0 , 1 ) . toUpperCase ( ) + result . substr ( 1 ) ; return result ; } }
+ * A more functional typeof
+ * @param Object o
+ * @return String
+
+ * A more functional typeof + *
Returns true type of something