Static content reports "File not found" when not running from document root.
The uweb page resides in the path /uweb/ and the static content resides in /uweb/static/. In router.py, this is configured as static path:
ROUTES = (('/uweb/', 'Index'),
If I open the static file /uweb/static/index.html uweb reports "This is not the path you're looking for. No such file u'/uweb/static/index.html'":
#1 Updated by Elmer de Looff over 7 years ago
- Status changed from New to Feedback
- Assignee set to Rudi Daemen
- Priority changed from Low to Normal
Where does this file reside on your disk, relative to the pagemaker that fulfills your requests? The default directory from which requests are fulfilled is the
'static' directory that is in the same directory as the
PageMaker is in. That is, if you your pagemaker is in
'/path/to/pagemaker/pages.py', then static files will start resolving in
If you have a request for http://fludizz.kratjebierhosting.nl/uweb/static/index.html, the file tried to access would be
'/path/to/pagemaker/static/index.html', with your provided route.
Does this function for you or not?
#3 Updated by Elmer de Looff over 7 years ago
- Status changed from Feedback to Closed
- % Done changed from 0 to 100
By default it requests from the
'static' relative directory. See also the documentation for serving static content.
I'm going to close this bug as it's not an actual bug. Should the documentation be lacking, unclear, or other suggestions / bugs be found, please open a new issue.