implement parse_params() and parse_cookies()