At Last The Static Stuff Is WorkingAt Last The Static Stuff Is Working2008-06-03 00:06:16Oh what a relief, I was trying to figure out why none of the static elements of the site were working. Well not really. I was actually trying to determine how the templates get all wrangled up when I noticed a lot of 404 error messages in the log files. Which is when I figured out why some of the site's interfaces were not working exactly right.
Turned out that although the template loaders for Django have a nice "go find the template relative to the application asking for it" feature. The static stuff like CSS pages, images and other elements do not have that ability. Instead they all ask for the /media/ directory. So what was breaking was two fold: I had a typo in the alias url definition I forgot the trailing slash. Curd I have been bitten by this in Apache and now in lighttpd too. If you alias a directory say "/media/" then you need to specify where to look for that directory and that needs to have a matching trailing slash. So I had this:
alias.url = (
"/media/" => "/srv/nodsw.com/media",
)
when what I was supposed to do was:
alias.url = (
"/media/" => "/srv/nodsw.com/media/",
)
Big time dooh! I even knew better. Oh well. It is fixed now. So thing are looking much better. Posted by Leeland 0 Comments |
|
| Comments: |
|---|
Page: 1
Please login to post a reply.

