Tin mới
urllib.parse — Parse URLs into components
Internet Protocols and Support
This module does not work or is not available on WebAssembly. See WebAssembly platforms for more information.
Open url, which can be either a string containing a valid, properly encoded URL, or a Request object.
Open url, which can be either a string containing a valid, properly encoded URL, or a Request object.
Changed in version 3.10: HTTPS connection now send an ALPN extension with protocol indicator http/1.1 when no context is given. Custom context should set ALPN protocols with set_alpn_protocols().
Convert the given file: URL to a local path. This function uses unquote() to decode the URL.
The http.cookiejar.CookieJar in which cookies are stored.
Handle an authentication request by getting a user/password pair, and re-trying the request. authreq should be the name of the header where the information about the realm is included in the request, host specifies the U
Handle an authentication request by getting a user/password pair, and re-trying the request. authreq should be the name of the header where the information about the realm is included in the request, host specifies the U
HOWTO Fetch Internet Resources Using The urllib Package
In addition to the examples below, more examples are given in HOWTO Fetch Internet Resources Using The urllib Package.
html.parser: A simple parser that can handle HTML and XHTML.
The data returned by urlopen() or urlretrieve() is the raw data returned by the server. This may be binary data (such as an image), plain text or (for example) HTML. The HTTP protocol provides type information in the rep
ftplib: FTP protocol client (requires sockets).
Returns the headers of the response in the form of an EmailMessage instance.