Thanks for your response!

I finally got it working. I was using the dev server and with your link
I was able to cobble together some responses there. After playing
around a bit I now see what is going on. One of the responses was that
maybe /media/ was "special" in some way. I was using that dir name.
Another responder said it wasn't special as long as ADMIN_MEDIA_ROOT
was not using the same dir name. Of course it was since Django sets it
up that way. Another thing, which I had to find out for myself, was
that there are two urlconf files, one in the project dir and another in
the app dir. I was placing the regex in the app dir and it doesn't work
from there, only in the project dir url.py file can the regex be
defined. I love Django, but this is a real showstopper when someone is
evaluating for possible use and then runs into such a ridiculous
problem. The developers say that this is to prevent people from using
an inefficient and insecure method of serving media. I suggest they
should just document it well, let the dev server serve the media and
stop trying to protect people from themselves. Their valiant effort to
protect is causing many people headaches over something that should be
totally transparent. Just my two cents....

On Jan 20, 2:23 pm, "Karen" <[EMAIL PROTECTED]> wrote:
> Are you using the development server?  If so, have you read and
> followed the instructions here:
>
> http://www.djangoproject.com/documentation/static_files/
>
> ?
>
> (I too started out by trying to set MEDIA_ROOT to get Django to serve
> up my stylesheets, but it won't do it.  It seems from various comments
> there is often confusion in this area when getting started.)
>
> If you are using apache or some other webserver, there are also some
> pointers on that page to other pages to guide setting up your
> production webserver to serve yourcssfiles.
>
> Hope this helps,
> Karen
>
> rsie wrote:
> > I'm having trouble getting my templates to recognize the location of my
> >cssfiles. I've set MEDIA_ROOT to /home/rsie/projects/django_templates
> > which has a directory media/cssunder it. The following is the
> > stylesheet line in my template: <link href="/media/css/default.css"
> > rel="stylesheet" type="text/css" />. Problem is it never resolves the
> > location correctly. Am I using MEDIA_ROOT correctly and if not does
> > anybody know what might be the problem?
> 
> > thanks
> > Ron


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to