mirror of
https://github.com/kennethreitz/requests.git
synced 2026-06-05 06:46:15 +00:00
Remove trailing whitespace from docs directory.
This commit is contained in:
+1
-1
@@ -1 +1 @@
|
|||||||
include HISTORY.rst README.rst LICENSE
|
include HISTORY.rst README.rst LICENSE
|
||||||
Vendored
+2
-2
@@ -1,9 +1,9 @@
|
|||||||
Modifications:
|
Modifications:
|
||||||
|
|
||||||
Copyright (c) 2011 Kenneth Reitz.
|
Copyright (c) 2011 Kenneth Reitz.
|
||||||
|
|
||||||
|
|
||||||
Original Project:
|
Original Project:
|
||||||
|
|
||||||
Copyright (c) 2010 by Armin Ronacher.
|
Copyright (c) 2010 by Armin Ronacher.
|
||||||
|
|
||||||
|
|||||||
Vendored
+1
-1
@@ -1,7 +1,7 @@
|
|||||||
krTheme Sphinx Style
|
krTheme Sphinx Style
|
||||||
====================
|
====================
|
||||||
|
|
||||||
This repository contains sphinx styles Kenneth Reitz uses in most of
|
This repository contains sphinx styles Kenneth Reitz uses in most of
|
||||||
his projects. It is a derivative of Mitsuhiko's themes for Flask and Flask related
|
his projects. It is a derivative of Mitsuhiko's themes for Flask and Flask related
|
||||||
projects. To use this style in your Sphinx documentation, follow
|
projects. To use this style in your Sphinx documentation, follow
|
||||||
this guide:
|
this guide:
|
||||||
|
|||||||
Vendored
+1
-1
@@ -4,4 +4,4 @@ stylesheet = flasky.css
|
|||||||
pygments_style = flask_theme_support.FlaskyStyle
|
pygments_style = flask_theme_support.FlaskyStyle
|
||||||
|
|
||||||
[options]
|
[options]
|
||||||
touch_icon =
|
touch_icon =
|
||||||
|
|||||||
+22
-22
@@ -8,11 +8,11 @@
|
|||||||
* :license: BSD, see LICENSE for details.
|
* :license: BSD, see LICENSE for details.
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@import url("basic.css");
|
@import url("basic.css");
|
||||||
|
|
||||||
/* -- page layout ----------------------------------------------------------- */
|
/* -- page layout ----------------------------------------------------------- */
|
||||||
|
|
||||||
body {
|
body {
|
||||||
font-family: 'Georgia', serif;
|
font-family: 'Georgia', serif;
|
||||||
font-size: 17px;
|
font-size: 17px;
|
||||||
@@ -35,7 +35,7 @@ div.bodywrapper {
|
|||||||
hr {
|
hr {
|
||||||
border: 1px solid #B1B4B6;
|
border: 1px solid #B1B4B6;
|
||||||
}
|
}
|
||||||
|
|
||||||
div.body {
|
div.body {
|
||||||
background-color: #ffffff;
|
background-color: #ffffff;
|
||||||
color: #3E4349;
|
color: #3E4349;
|
||||||
@@ -46,7 +46,7 @@ img.floatingflask {
|
|||||||
padding: 0 0 10px 10px;
|
padding: 0 0 10px 10px;
|
||||||
float: right;
|
float: right;
|
||||||
}
|
}
|
||||||
|
|
||||||
div.footer {
|
div.footer {
|
||||||
text-align: right;
|
text-align: right;
|
||||||
color: #888;
|
color: #888;
|
||||||
@@ -55,12 +55,12 @@ div.footer {
|
|||||||
width: 650px;
|
width: 650px;
|
||||||
margin: 0 auto 40px auto;
|
margin: 0 auto 40px auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
div.footer a {
|
div.footer a {
|
||||||
color: #888;
|
color: #888;
|
||||||
text-decoration: underline;
|
text-decoration: underline;
|
||||||
}
|
}
|
||||||
|
|
||||||
div.related {
|
div.related {
|
||||||
line-height: 32px;
|
line-height: 32px;
|
||||||
color: #888;
|
color: #888;
|
||||||
@@ -69,18 +69,18 @@ div.related {
|
|||||||
div.related ul {
|
div.related ul {
|
||||||
padding: 0 0 0 10px;
|
padding: 0 0 0 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
div.related a {
|
div.related a {
|
||||||
color: #444;
|
color: #444;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* -- body styles ----------------------------------------------------------- */
|
/* -- body styles ----------------------------------------------------------- */
|
||||||
|
|
||||||
a {
|
a {
|
||||||
color: #004B6B;
|
color: #004B6B;
|
||||||
text-decoration: underline;
|
text-decoration: underline;
|
||||||
}
|
}
|
||||||
|
|
||||||
a:hover {
|
a:hover {
|
||||||
color: #6D4100;
|
color: #6D4100;
|
||||||
text-decoration: underline;
|
text-decoration: underline;
|
||||||
@@ -89,7 +89,7 @@ a:hover {
|
|||||||
div.body {
|
div.body {
|
||||||
padding-bottom: 40px; /* saved for footer */
|
padding-bottom: 40px; /* saved for footer */
|
||||||
}
|
}
|
||||||
|
|
||||||
div.body h1,
|
div.body h1,
|
||||||
div.body h2,
|
div.body h2,
|
||||||
div.body h3,
|
div.body h3,
|
||||||
@@ -109,24 +109,24 @@ div.indexwrapper h1 {
|
|||||||
height: {{ theme_index_logo_height }};
|
height: {{ theme_index_logo_height }};
|
||||||
}
|
}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
div.body h2 { font-size: 180%; }
|
div.body h2 { font-size: 180%; }
|
||||||
div.body h3 { font-size: 150%; }
|
div.body h3 { font-size: 150%; }
|
||||||
div.body h4 { font-size: 130%; }
|
div.body h4 { font-size: 130%; }
|
||||||
div.body h5 { font-size: 100%; }
|
div.body h5 { font-size: 100%; }
|
||||||
div.body h6 { font-size: 100%; }
|
div.body h6 { font-size: 100%; }
|
||||||
|
|
||||||
a.headerlink {
|
a.headerlink {
|
||||||
color: white;
|
color: white;
|
||||||
padding: 0 4px;
|
padding: 0 4px;
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
a.headerlink:hover {
|
a.headerlink:hover {
|
||||||
color: #444;
|
color: #444;
|
||||||
background: #eaeaea;
|
background: #eaeaea;
|
||||||
}
|
}
|
||||||
|
|
||||||
div.body p, div.body dd, div.body li {
|
div.body p, div.body dd, div.body li {
|
||||||
line-height: 1.4em;
|
line-height: 1.4em;
|
||||||
}
|
}
|
||||||
@@ -164,25 +164,25 @@ div.note {
|
|||||||
background-color: #eee;
|
background-color: #eee;
|
||||||
border: 1px solid #ccc;
|
border: 1px solid #ccc;
|
||||||
}
|
}
|
||||||
|
|
||||||
div.seealso {
|
div.seealso {
|
||||||
background-color: #ffc;
|
background-color: #ffc;
|
||||||
border: 1px solid #ff6;
|
border: 1px solid #ff6;
|
||||||
}
|
}
|
||||||
|
|
||||||
div.topic {
|
div.topic {
|
||||||
background-color: #eee;
|
background-color: #eee;
|
||||||
}
|
}
|
||||||
|
|
||||||
div.warning {
|
div.warning {
|
||||||
background-color: #ffe4e4;
|
background-color: #ffe4e4;
|
||||||
border: 1px solid #f66;
|
border: 1px solid #f66;
|
||||||
}
|
}
|
||||||
|
|
||||||
p.admonition-title {
|
p.admonition-title {
|
||||||
display: inline;
|
display: inline;
|
||||||
}
|
}
|
||||||
|
|
||||||
p.admonition-title:after {
|
p.admonition-title:after {
|
||||||
content: ":";
|
content: ":";
|
||||||
}
|
}
|
||||||
@@ -254,7 +254,7 @@ dl {
|
|||||||
dl dd {
|
dl dd {
|
||||||
margin-left: 30px;
|
margin-left: 30px;
|
||||||
}
|
}
|
||||||
|
|
||||||
pre {
|
pre {
|
||||||
padding: 0;
|
padding: 0;
|
||||||
margin: 15px -30px;
|
margin: 15px -30px;
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ Make a Request
|
|||||||
Making a request with Requests is very simple.
|
Making a request with Requests is very simple.
|
||||||
|
|
||||||
Begin by importing the Requests module::
|
Begin by importing the Requests module::
|
||||||
|
|
||||||
>>> import requests
|
>>> import requests
|
||||||
|
|
||||||
Now, let's try to get a webpage. For this example, let's get GitHub's public
|
Now, let's try to get a webpage. For this example, let's get GitHub's public
|
||||||
@@ -37,12 +37,12 @@ information we need from this object.
|
|||||||
|
|
||||||
Requests' simple API means that all forms of HTTP request are as obvious. For
|
Requests' simple API means that all forms of HTTP request are as obvious. For
|
||||||
example, this is how you make an HTTP POST request::
|
example, this is how you make an HTTP POST request::
|
||||||
|
|
||||||
>>> r = requests.post("http://httpbin.org/post")
|
>>> r = requests.post("http://httpbin.org/post")
|
||||||
|
|
||||||
Nice, right? What about the other HTTP request types: PUT, DELETE, HEAD and
|
Nice, right? What about the other HTTP request types: PUT, DELETE, HEAD and
|
||||||
OPTIONS? These are all just as simple::
|
OPTIONS? These are all just as simple::
|
||||||
|
|
||||||
>>> r = requests.put("http://httpbin.org/put")
|
>>> r = requests.put("http://httpbin.org/put")
|
||||||
>>> r = requests.delete("http://httpbin.org/delete")
|
>>> r = requests.delete("http://httpbin.org/delete")
|
||||||
>>> r = requests.head("http://httpbin.org/get")
|
>>> r = requests.head("http://httpbin.org/get")
|
||||||
@@ -70,7 +70,7 @@ You can see that the URL has been correctly encoded by printing the URL::
|
|||||||
|
|
||||||
>>> print r.url
|
>>> print r.url
|
||||||
u'http://httpbin.org/get?key2=value2&key1=value1'
|
u'http://httpbin.org/get?key2=value2&key1=value1'
|
||||||
|
|
||||||
|
|
||||||
Response Content
|
Response Content
|
||||||
----------------
|
----------------
|
||||||
@@ -229,7 +229,7 @@ You can set the filename explicitly::
|
|||||||
If you want, you can send strings to be received as files::
|
If you want, you can send strings to be received as files::
|
||||||
|
|
||||||
>>> url = 'http://httpbin.org/post'
|
>>> url = 'http://httpbin.org/post'
|
||||||
>>> files = {'file': ('report.csv', 'some,data,to,send\nanother,row,to,send\n')}
|
>>> files = {'file': ('report.csv', 'some,data,to,send\nanother,row,to,send\n')}
|
||||||
|
|
||||||
>>> r = requests.post(url, files=files)
|
>>> r = requests.post(url, files=files)
|
||||||
>>> r.text
|
>>> r.text
|
||||||
|
|||||||
Reference in New Issue
Block a user