django-fileman adds user-uploaded static files to the django admin (i.e. images, media, documents) and integrates with tinymce
Requirements
Python 2.7, 3.4 or 3.5
Django 1.8+
Installation
Download the source from https://pypi.python.org/pypi/django-fileman/ and run python setup.py install, or:
> pip install django-fileman
Add fileman to INSTALLED_APPS
Set FILEMAN_DIRECTORY to a subdirectory of your MEDIA_ROOT (make sure it exists, it won’t be created). Defaults to 'user'
Make sure the django admin is installed correctly
Usage
You should now have an “Uploads” section in your django admin which allows you to manage/upload files under your FILEMAN_DIRECTORY.
TinyMCE
There are two options for TinyMCE integration. The simplest is to set TinyMCE’s link_list parameter to the url for ‘admin:fileman_link_list’, i.e.
tinymce.init({
selector: 'textarea',
plugins : 'link',
link_list: '{% url "admin:fileman_link_list" %}',
toolbar: 'link'
});
this should work with any modern TinyMCE version (from 3 onwards)
Alternately, set TinyMCE’s file_picker_callback option to integrate with the image, media and link dialogs. For example, in your admin/base_site.html template:
<script type="text/javascript"
src="{% static 'tinymce/tinymce.min.js' %}"></script>
{% include 'fileman/static.html' %}
<script type="text/javascript" charset="utf-8">
tinymce.init({
selector: 'textarea',
plugins : 'link media image',
file_picker_callback: window.fileman.tinymceFilePickerCallback,
toolbar: 'link media image'
});
</script>
TinyMCE 4.x is required.
Running tests
Use tox (https://pypi.python.org/pypi/tox):
> pip install tox > cd path-to/django-fileman > tox
Metadata
Release files for django-fileman 1.0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| django-fileman-1.0.3.tar.gz | 12.6 kB | Without provenance | Details |
Release files / django-fileman-1.0.3.tar.gz
| Download URL | django-fileman-1.0.3.tar.gz |
|---|---|
| Size | 12.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e386baeacf0ef3d6508bb370fd0688cb9f6ce23942095991045f04f68188e158
|
|
BLAKE2b-256 checksum How to use checksums |
e9b864604cd45d13e9cf9a6ffe4722e1c759957530ee1cdd971150d11d573bc6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for django-fileman 1.0.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.