Errno 13 when uploading pictures

9 views
Skip to first unread message

R.N. George

unread,
May 7, 2015, 11:05:57 PM5/7/15
to django...@googlegroups.com
I'm trying to upload a picture through my admin page and keep getting Errno 13.I have no clue what is going wrong, any help would be great.

Here are the lines of code from my model, 

   
 image_object = models.ImageField(db_column='IMAGE_OBJECT',upload_to = "/media/", blank=True) # Field name made lowercase.


setting, 

    ENV_PATH = os.path.abspath(os.path.dirname(os.path.dirname(__file__)))
    MEDIA_ROOT
= os.path.join(ENV_PATH, '/media/')
    MEDIA_URL
= "/media/"


and httpd.conf files

    Alias /media /path_to_media_folder/media/
   
   
<Directory /path_to_media_folder/media>
   
Require all granted
   
</Directory>

I have already used chmod 777 on the media file fyi
Reply all
Reply to author
Forward
0 new messages