I absolutely agree with bennylope's answer -- make sure you have a Django project running before trying to incorporate django-cms.
Once you do have the skeleton django project up, you'll probably want to add this to the bottom of your root urls.py
file:
urlpatterns += patterns('',
url(r'^', include('cms.urls')),
)
In your settings.py
file, make sure that you have added the following to INSTALLED_APPS
:
'cms',
'cms.plugins.text',
'cms.plugins.picture',
'cms.plugins.link',
'cms.plugins.file',
'cms.plugins.snippet',
'cms.plugins.googlemap',
'mptt',
'menus',
'publisher',
Don't bother copying over the example folder. However, you do need to set up your starting CMS templates.
In your root project folder, create a folder templates
if you haven't already done so. You need to create a file for outputing the CMS, here is a good start:
# default.html
{% extends "base.html" %}
{% load cache cms_tags menu_tags %}
{% block menu %}
<ul id="navigation">
{% show_menu 0 100 100 100 %}
</ul>
{% endblock menu %}
{% block content %}
<ul class="breadcrumb">
<li class="you">You are here:</li>
{% show_breadcrumb %}
</ul>
<h1>{% block title %}{% page_attribute title %}{% endblock %}</h1>
<div>
<div class="placeholder" id="body">
{% placeholder "body" %}
</div>
</div>
{% endblock content %}
Make sure to add
CMS_TEMPLATES = (
('default.html', gettext('default')),
)
to your settings file.
You're responsible for setting up base.html
. However you write it, make sure it includes {% block content %}{% endblock content %}
somewhere so the contents of the CMS template get displayed.
I'd actually recommend against copying the django-cms folders into your /eck directory. They should be located wherever site-packages
or the equivalent is located in your install. My favorite way to set this up is to put django-cms in /opt/
and then use symbolic linking to the subfolders in site-packages
. This may not work for you, get in touch with whomever manages your shared hosting to ask them what to do, as it is often different for each provider.
However, the key is you don't want to have the django-cms folders in the same area as your project folders. When setting up a django project, I personally like to keep separate the apps I've coded specifically for this project from other apps.