We’ll get started by setting up our environment.
We’re going to assume that you have a reasonably recent version of virtualenv installed and that you have some basic familiarity with it.
virtualenv env
source env/bin/activate
Note that if you’re using Windows, to activate the virtualenv you’ll need:
env\Scripts\activate
The django CMS installer is a helpful script that takes care of setting up a new project.
Install it:
pip install djangocms-installer
This provides you with a new command, djangocms.
Create a new directory to work in, and cd into it:
mkdir tutorial-project
cd tutorial-project
Run it to create a new Django project called mysite:
djangocms -p . mysite
Windows users may need to do a little extra to make sure Python files are associated correctly if that doesn’t work right away:
assoc .py=Python.file
ftype Python.File="C:\Users\Username\workspace\demo\env\Scripts\python.exe" "%1" %*
For the purposes of this tutorial, it’s recommended that you answer the installer’s questions as follows - where our suggestions differ from the default, they’re highlighted below:
Create a Django admin user when invited.
python manage.py runserver
Open http://localhost:8000/ in your browser, where you should be presented with your brand new django CMS homepage.
Congratulations, you now have installed a fully functional CMS!
To log in, append ?edit to the URL and hit enter. This will enable the toolbar, from where you can log in and manage your website. Switch to Draft mode to add and edit content.
Try to switch between Live and Draft view, between Structure and Content mode, add plugins, move them around and delete them again.
To add a Text or or other plugin elements to a placeholder: