public function getVar($whatVar, $default = null)
    {
        if (is_numeric($whatVar)) {
            $whatVar = (int)$whatVar + 1;

            if (isset($this->uri[$whatVar])) {
                $value = trim($this->uri[$whatVar]);
                return ($value != '') ? $value : $default;
            } else {
                return $default;
            }
        } else {
            // if variable is string, then treat it like GET parameter
            if (isset($_GET[$whatVar])) {
                $value = trim($_GET[$whatVar]);
                return ($value != '') ? $value : $default;
            } else {
                return $default;
            }
        }
    }