示例#1
0
        if (SHOW_QUERY_LOG) {
            printQueryLogFirePhp();
        }
        exit;
    }
    /**
     * Returns the installed version string
     * @return stirng
     */
    public static function version()
    {
        return DB::getVar("select version from bt_g_version");
    }
    public static function autoload($name)
    {
        if (substr($name, -5) == 'Model') {
            self::importModel($name);
        }
    }
}
spl_autoload_register(array('BTApp', 'autoload'));
function joinControllerName($parts, $limit)
{
    $name = '';
    for ($i = 0; $i < $limit; $i++) {
        $name .= ucfirst($parts[$i]);
    }
    return $name . 'Controller';
}
BTApp::init();