Well, this is mostly a reminder for myself on how to do this. The goal is to set up a generic "HTMLField" for models, which you can add photos to as well.
Here are the steps:
- Install django-tinymce4-lite
- Install django-filebrowser-no-grappelli
- In your settings.py, addX_FRAME_OPTIONS = 'sameorigin'(the filebrowser uses an iFrame which gets blocked by default)
- Let's say your MEDIA_ROOT is /media, and you want to upload files to/media/uploads. Insettings.py, addFILEBROWSER_DIRECTORY = 'uploads/'. Then, make sure/media/uploadsactually is a folder, or you will see an error.
 

 
    
Top comments (0)