require_once __DIR__ . '/sandbox/system/init.php';
/*
 * Determine and execute a generic method of implementation 
 */
switch (PLATFORM_ENGINE) {
    case 'object':
        // using object-orientation <strict adherence>
        require_once PLATFORM_SANDBOX_SYSTEM_CLASSES_PATH . DS . 'platform.php';
        $platform = new Platform();
        break;
    case 'objects':
        // using object-orientation <stdlib re-use>
        require_once PLATFORM_SANDBOX_SYSTEM_CLASSES_PATH . DS . 'standards/platform.php';
        $platform = new Platform();
        break;
    case 'stdlib':
        // using procedural <optimal use>
    // using procedural <optimal use>
    default:
        require_once PLATFORM_SANDBOX_SYSTEM_FUNCTIONS_PATH . DS . 'platform.php';
        platform();
        break;
}
/**
 * Detect browser type
 */
if (is_chrome() || is_chromium() || is_safari()) {
    // do nothing
} else {
    //redirect_to('http://www.google.com');
}
function get_device_type()
{
    $device_type = 'Unknown';
    switch (true) {
        // Windows
        case is_windows() && is_firefox():
            $device_type = 'Windows Firefox';
            break;
        case is_windows() && is_chromium():
            $device_type = 'Windows Chromium';
            break;
        case is_windows() && is_chrome():
            $device_type = 'Windows Chrome';
            break;
        case is_windows() && is_safari():
            $device_type = 'Windows Safari';
            break;
        case is_windows() && is_opera():
            $device_type = 'Windows Opera';
            break;
        case is_windows() && is_ie():
            $device_type = 'Windows IE';
            break;
            // Apple Macintosh
        // Apple Macintosh
        case is_macintosh() && is_firefox():
            $device_type = 'Apple Firefox';
            break;
        case is_macintosh() && is_chromium():
            $device_type = 'Apple Chromium';
            break;
        case is_macintosh() && is_chrome():
            $device_type = 'Apple Chrome';
            break;
        case is_macintosh() && is_safari():
            $device_type = 'Apple Safari';
            break;
        case is_macintosh() && is_opera():
            $device_type = 'Apple Opera';
            break;
        case is_macintosh() && is_ie():
            $device_type = 'Apple IE';
            break;
            // Ubuntu
        // Ubuntu
        case is_ubuntu() && is_firefox():
            $device_type = 'Ubuntu Firefox';
            break;
        case is_ubuntu() && is_chromium():
            $device_type = 'Ubuntu Chromium';
            break;
        case is_ubuntu() && is_chrome():
            $device_type = 'Ubuntu Chrome';
            break;
        case is_ubuntu() && is_safari():
            $device_type = 'Ubuntu Safari';
            break;
        case is_ubuntu() && is_opera():
            $device_type = 'Ubuntu Opera';
            break;
        case is_ubuntu() && is_ie():
            $device_type = 'Ubuntu IE';
            break;
            // Linux
        // Linux
        case is_linux() && is_firefox():
            $device_type = 'Linux Firefox';
            break;
        case is_linux() && is_chromium():
            $device_type = 'Linux Chromium';
            break;
        case is_linux() && is_chrome():
            $device_type = 'Linux Chrome';
            break;
        case is_linux() && is_safari():
            $device_type = 'Linux Safari';
            break;
        case is_linux() && is_opera():
            $device_type = 'Linux Opera';
            break;
        case is_linux() && is_ie():
            $device_type = 'Linux IE';
            break;
    }
    return $device_type;
}