How doesn't it work?
1. Does the uploaded file appear where you expect it to?
2. If you construct the URL properly in your browser, can you access
it directly?
3. What is the URL being output in your templates?
On Tue, Apr 14, 2015 at 9:44 AM, dk wrote:
> maybe I need to simplify my question.
>
maybe I need to simplify my question.
how do I use media_url in windows?
On Wednesday, April 8, 2015 at 10:56:27 AM UTC-5, dk wrote:
> in my settings
> MEDIA_ROOT = os.path.join(BASE_DIR, 'media')
> MEDIA_URL = "/media/"
>
>
> my view to accept files.
> def request_page(request):
> #tod
You should def. read those articles. A quick fix (if you're in a time
crunch) is to add this to your base urls.py inserting the proper values:
if settings.DEBUG:
urlpatterns += patterns('',
(r'^my_sites_media_folder/(?P.*)$', 'django.views.static.serve',
{'document_root': '/path/to/my
Have a look at the links below, I think you're over-estimating what
MEDIA_URL does for you -
http://www.djangoproject.com/documentation/static_files/
http://www.djangoproject.com/documentation/settings/#media-url
On Feb 22, 7:54 pm, troeten <[EMAIL PROTECTED]> wrote:
> Hi,
> i have a problem with
http://www.djangoproject.com/documentation/static_files/
troeten wrote:
> Hi,
> i have a problem with the MEDIA_URL in django.
> My settings.py section looks like this:
>
> # Absolute path to the directory that holds media.
> # Example: "/home/media/media.lawrence.com/"
> MEDIA_ROOT = '/Users/ste
5 matches
Mail list logo