Ok, but Static_root in settings.py is empty, so i import static_url or
staticfiles_dirs ?
In static_url there is define '/static/'
In staticfiles_dirs are define: (
    '/home/alessandro/Scrivania/progetto/media/photos/custodia/',
    '/home/alessandro/Scrivania/progetto/media/definitiva/',
    '/home/alessandro/Scrivania/progetto/media/proforma/',
    '/home/alessandro/Scrivania/progetto/media/fpdf/',
)

So in urls.py, in theory I must import that directory.

Then in settings.py, in head, import:
from django.contrib.staticfiles.urls import staticfiles_urlpatterns

(
https://docs.djangoproject.com/en/1.4/howto/static-files/#staticfiles-development
)
and add

urlpatterns += staticfiles_urlpatterns()

But if I realod the admin page, and i find to see the image file or
pdf file, the page not found:
'alessandro/Scrivania/progetto/media/photos/custodia/shop-ad.jpg'
could not be found

Now, I don't know what to do.
Certainly this a Stupid Problem, but I am a New Users in Django, and
I'm sorry for my english. :-(

------------------------------------------------------------------------------------------------------------------------------------
*Dott. Tegagni Alessandro*
Consulente nel settore delle Tecnologie Informatiche
Siti Web e Applicazioni Mobile

Ufficio di Cremona:
Via Fatebenefratelli, 2 - 26100 Cremona (Cr)
Tel. 333/9118728
P.Iva 01521350197

Sito Web <http://www.alessandrotegagni.com>

--------------------------------------------------------------------------------------------------------------------------------
("Le informazioni contenute nella presente comunicazione possono essere
riservate e sono, comunque, destinate alle persone o alla società sopra
indicati. La diffusione, distribuzione e/o copiatura del documento
trasmesso da parte di qualsiasi soggetto diverso dal destinatario è
proibita, sia ai sensi dell'art.616 c.p.c. che ai sensi del D.Lgs.n.
196/2003.

Se avete ricevuto questo messaggio per errore, vi preghiamo cortesemente di
cancellarlo ed informarci immediatamente.")



2012/7/12 Dennis Lee Bieber <wlfr...@ix.netcom.com>

> On Thu, 12 Jul 2012 01:30:35 +0200, "Dott. Tegagni Alessandro"
> <tefari....@gmail.com> declaimed the following in
> gmane.comp.python.django.user:
>
> > Thanks Dennis, in settings.py, the situation are:
> >
>
>         It's not the "settings.py" file I'm interested in... It's
> django.conf.settings.py that is active in your later usage. Unless the
> two are somehow the same file you may not be accessing what you think
> you are!
>
>         What you typed as
>
> from settings import STATIC_ROOT
> from django.conf import settings
> ...
> {'document_root', settings.STATIC_ROOT})
>
> is, based on your imports, the same as
>
> import django
> ...
> {'document_root', django.conf.settings.STATIC_ROOT})
>
>         If you want the STATIC_ROOT from
>
> from settings import STATIC_ROOT
>
> then you need to use
>
> ...
> {'document_root', STATIC_ROOT})
>
>
>
> --
>         Wulfraed                 Dennis Lee Bieber         AF6VN
>         wlfr...@ix.netcom.com    HTTP://wlfraed.home.netcom.com/
>
> --
> 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
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>
>

-- 
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 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to