Chris McDonough
2011-08-20 b8c79771a186f1032635fc640b3cecc2c9e281ad
refs
author Chris McDonough <chrism@plope.com>
Saturday, August 20, 2011 19:05 +0200
committer Chris McDonough <chrism@plope.com>
Saturday, August 20, 2011 19:05 +0200
commitb8c79771a186f1032635fc640b3cecc2c9e281ad
tree c329dfaf72b40ae2358423a78d48fefd0f5752b4 tree | zip | gz
parent 5c6963152fcc756a06d2aea80a4e85f1c9bef7ee view | diff
- The ``pyramid.request.Request.static_url`` API (and its brethren
``pyramid.request.Request.static_path``, ``pyramid.url.static_url``, and
``pyramid.url.static_path``) now accept an asbolute filename as a "path"
argument. This will generate a URL to an asset as long as the filename is
in a directory which was previously registered as a static view.
Previously, trying to generate a URL to an asset using an absolute file
path would raise a ValueError.
3 files modified
84 ■■■■ changed files
CHANGES.txt 8 ●●●●● diff | view | raw | blame | history
pyramid/tests/test_url.py 42 ●●●●● diff | view | raw | blame | history
pyramid/url.py 34 ●●●●● diff | view | raw | blame | history