diff options
author | Guido van Rossum <guido@python.org> | 1995-02-27 17:51:51 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 1995-02-27 17:51:51 (GMT) |
commit | 61d34f47c39c9ae96771b04ba090d70ffc28db71 (patch) | |
tree | 381b8a09700ee29166342499b8ea2433b8968846 /Doc/lib/liburllib.tex | |
parent | d6304d09cc1ad5792356df1ab412dc0c0303814c (diff) | |
download | cpython-61d34f47c39c9ae96771b04ba090d70ffc28db71.zip cpython-61d34f47c39c9ae96771b04ba090d70ffc28db71.tar.gz cpython-61d34f47c39c9ae96771b04ba090d70ffc28db71.tar.bz2 |
added quote and unquote
Diffstat (limited to 'Doc/lib/liburllib.tex')
-rw-r--r-- | Doc/lib/liburllib.tex | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/Doc/lib/liburllib.tex b/Doc/lib/liburllib.tex index 49bc416..689a5c9 100644 --- a/Doc/lib/liburllib.tex +++ b/Doc/lib/liburllib.tex @@ -2,7 +2,7 @@ \stmodindex{urllib} \index{WWW} \indexii{World-Wide}{Web} -\index{URLs} +\index{URL} This module provides a high-level interface for fetching data across the World-Wide Web. In particular, the \code{urlopen} function is @@ -49,6 +49,21 @@ Clear the cache that may have been built up by previous calls to \code{urlretrieve()}. \end{funcdesc} +\begin{funcdesc}{quote}{string\optional{\, addsafe}} +Replace special characters in \var{string} using the \code{\%xx} escape. +Letters, digits, and the characters ``\code{_,.-}'' are never quoted. +The optional \var{addsafe} parameter specifies additional characters +that should not be quoted --- its default value is \code{'/'}. + +Example: \code{quote('/~conolly/')} yields \code{'/\%7econnolly/'}. +\end{funcdesc} + +\begin{funcdesc}{unquote}{string} +Remove \code{\%xx} escapes by their single-character equivalent. + +Example: \code{unquote('/\%7Econnolly/')} yields \code{'/~connolly/'}. +\end{funcdesc} + Restrictions: \begin{itemize} |