summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorChris McDonough <chrism@plope.com>2012-02-24 14:52:34 -0500
committerChris McDonough <chrism@plope.com>2012-02-24 14:52:34 -0500
commit6c2bf5f122e60e07f03b9bdda9f57b5a275e7c25 (patch)
treeb4838a2baf1a1ca9d40173a76da6c40315e0fa2a /docs
parent3a8cee594c3e42dd23cde72310c71aa816e3a966 (diff)
parent905bcaaec5f71f9b2df4204ed91c1628f854e0ff (diff)
downloadpyramid-6c2bf5f122e60e07f03b9bdda9f57b5a275e7c25.tar.gz
pyramid-6c2bf5f122e60e07f03b9bdda9f57b5a275e7c25.tar.bz2
pyramid-6c2bf5f122e60e07f03b9bdda9f57b5a275e7c25.zip
Merge branch '1.3-branch'
Diffstat (limited to 'docs')
-rw-r--r--docs/narr/assets.rst13
1 files changed, 6 insertions, 7 deletions
diff --git a/docs/narr/assets.rst b/docs/narr/assets.rst
index 22b38c929..e8e915297 100644
--- a/docs/narr/assets.rst
+++ b/docs/narr/assets.rst
@@ -379,13 +379,12 @@ do so, do things "by hand". First define the view callable.
The above bit of code within ``favicon_view`` computes "here", which is a
path relative to the Python file in which the function is defined. It then
-uses the Python ``open`` function to obtain a file handle to a file within
-"here" named ``static``, and returns a :class:`pyramid.response.FileResponse`
-using the file path as the response's ``path`` argument and the request as
-the response's ``request`` argument. :class:`pyramid.response.FileResponse`
-will serve the file as quickly as possible when it's used this way. It makes
-sure to set the right content length and content_type too based on the file
-extension of the file you pass.
+creates a :class:`pyramid.response.FileResponse` using the file path as the
+response's ``path`` argument and the request as the response's ``request``
+argument. :class:`pyramid.response.FileResponse` will serve the file as
+quickly as possible when it's used this way. It makes sure to set the right
+content length and content_type too based on the file extension of the file
+you pass.
You might register such a view via configuration as a view callable that
should be called as the result of a traversal: