ronbeltran / django-pages

Add pages to a django site quickly with flatpages app and ckeditor

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Django Pages

image

image

image

Add pages to a django site quickly with flatpages app and ckeditor

Documentation

The full documentation is at TODO: https://django-pages.readthedocs.io.

Quickstart

Install the Django flatpages app

https://docs.djangoproject.com/en/1.11/ref/contrib/flatpages/

Install the django-ckeditor app

https://django-ckeditor.readthedocs.io/en/latest/index.html#installation

Install Django Pages:

pip install -e git+https://github.com/ronbeltran/django-pages@master#egg=django-pages

Add it to your `INSTALLED_APPS`:

INSTALLED_APPS = (
    ...
    'django.contrib.flatpages',
    'ckeditor',
    'ckeditor_uploader',
    'pages',
    ...
)

MIDDLEWARE = [
    ...
    'django.contrib.flatpages.middleware.FlatpageFallbackMiddleware',
    ...
]

Add Django Pages's URL patterns:

urlpatterns = [
    ...
    url(r'^pages/', include('django.contrib.flatpages.urls')),
    url(r'^ckeditor/', include('ckeditor_uploader.urls')),
    ...
]

Add in settings

CKEDITOR_UPLOAD_PATH = "uploads/"
CKEDITOR_IMAGE_BACKEND = "pillow"

For more details and customization with the ckeditor please see django-ckeditor

Make sure you have run the ff:

python manage.py migrate
python manage.py collectstatic --noinput

Features

  • TODO

Running Tests

Does the code actually work?

source <YOURVIRTUALENV>/bin/activate
(myenv) $ pip install tox
(myenv) $ tox

Credits

Tools used in rendering this package:

About

Add pages to a django site quickly with flatpages app and ckeditor

License:MIT License


Languages

Language:Python 72.3%Language:Makefile 20.0%Language:HTML 7.7%