As I explain before, my problem was the use of 'media' as directory for
static files
media/css/*.css
media/images/*.png
media/js/*.js
when I replace media by site-media, all work with this URL
#fichiers statiques (images, css, ...)
urlpatterns += patterns('',
(r'^site_media/(?P.*)$', 'djan
I finally found it, put this in your urls(this works to me!):
(r'(^|/)css/(?P.*)$',
'django.views.static.serve',
{'document_root': 'templates/css/', 'show_indexes': True}),
Maybe you already do that... but just for another that have the same
problem :-P
--
http
Jean-Luc a écrit :
> I used media in place of site_media for directory name
> It seems media shouldn't be used ?
As media is set/defined for media admin in settings.py, I guess there is
a conflict between the two values. With a different name (like
site_media) it works.
> Thanks Nicolas
You'
Nicolas Steinmetz a écrit :
> Jean-Luc wrote:
>
> > igor Guerrero a écrit :
> >
> >> Django dont serve media files, that is the job of the production server
> >> but if yo are using the development server: you can try this:
> >>
> >> http://www.djangoproject.com/documentation/static_files/
>
> Ba
Jean-Luc wrote:
> igor Guerrero a écrit :
>
>> Django dont serve media files, that is the job of the production server
>> but if yo are using the development server: you can try this:
>>
>> http://www.djangoproject.com/documentation/static_files/
Based on above doc, I had same trouble as you Je
igor Guerrero a écrit :
> Django dont serve media files, that is the job of the production server but
> if yo are using the development server: you can try this:
>
> http://www.djangoproject.com/documentation/static_files/
>
> On 11/13/06, Jean-Luc <[EMAIL PROTECTED]> wrote:
> >
> >
> > Jay Parla
Django dont serve media files, that is the job of the production server but if yo are using the development server: you can try this:http://www.djangoproject.com/documentation/static_files/
On 11/13/06, Jean-Luc <[EMAIL PROTECTED]> wrote:
Jay Parlar a écrit :> On 11/13/06, Jean-Luc <[EMAIL PROTECTE
Jay Parlar a écrit :
> On 11/13/06, Jean-Luc <[EMAIL PROTECTED]> wrote:
> >
> > hi Django folks
> >
> > newbie question, style sheet not found
> >
> > my base.html
> >
> >
> >> type="text/css" media="screen"/>
>
> That's your problem right there, you have the 'media' folder as a
> relativ
On 11/13/06, Jean-Luc <[EMAIL PROTECTED]> wrote:
>
> hi Django folks
>
> newbie question, style sheet not found
>
> my base.html
>
>
>type="text/css" media="screen"/>
That's your problem right there, you have the 'media' folder as a
relative URL. Look at the request, it's trying to get:
hi Django folks
newbie question, style sheet not found
my base.html
...
My urls.py
urlpatterns = patterns('',
# Admin
(r'^admin/', include('django.contrib.admin.urls')),
)
# par date
urlpatterns += patterns('django.views.generic.date_based',
(r'^budget/(?P\d{4})/(?P\d{2})
10 matches
Mail list logo