/**
 * This is base class of many projects 
 * developed by our team
 */

_ = function ( element_id ) { return document.getElementById( element_id ) || false }

function Base () {
    /**
     * FOR TAB.CLASS
     */
    this.tab_css_active     = "active";
    this.tab_css_current    = "current";
    this.tab_css_base       = "list_ol_tab";
    this.tab_prefix_link    = "_link_";
    this.tab_prefix_ul      = "_ul";
    this.tab_block_div      = "_block_";
    this.tab_tag_container  = "ol";
    this.tab_tag_element    = "li";
    this.tab_timeout        = 1000;
    this.tab_delta_id       = 0;
    this.Browser = {
        IE:     !!(window.attachEvent && !window.opera),
        Opera:  !!window.opera,
        WebKit: navigator.userAgent.indexOf('AppleWebKit/') > -1,
        Gecko:  navigator.userAgent.indexOf('Gecko') > -1 && navigator.userAgent.indexOf('KHTML') == -1,
        MobileSafari: !!navigator.userAgent.match(/Apple.*Mobile.*Safari/)
    };
    this.json_url           = '/exec/json.php';
    
    /**
     * FOR CAROUSEL.CLASS
     */
    this.carousel_css_normal= "mrt_null";
    this.carousel_block_name= "block";
    
    /**
     * Methods
     */
    this.in_array = function (el, arr) {
        for (var i = 0; i < arr.length; i++) {
            if (el == arr[i])
                return true;
        }
        return false;
    }
    
}