Permalink
Browse files

Using tinymce plugin

  • Loading branch information...
1 parent 9bb6e90 commit 87c76276a0ebe2e603018def41b0a397a3724248 @bianchimro committed Mar 9, 2012
Showing with 47 additions and 0 deletions.
  1. +43 −0 bianchimro/settings.py
  2. +3 −0 bianchimro/urls.py
  3. +1 −0 requirements.txt
View
@@ -147,6 +147,8 @@
'south',
'sekizai',
+ 'tinymce',
+
#the following plugins should be disabled, if using filer plugins
'cms.plugins.file',
'cms.plugins.picture',
@@ -158,6 +160,7 @@
'cms.plugins.link',
'cms.plugins.snippet',
'cms.plugins.text',
+
'cms.plugins.twitter',
'tagging',
@@ -197,6 +200,46 @@
]
+#cms default editor config -- we could switch to tinymce ..
+WYM_TOOLS = ",\n".join([
+ "{'name': 'Bold', 'title': 'Strong', 'css': 'wym_tools_strong'}",
+ "{'name': 'Italic', 'title': 'Emphasis', 'css': 'wym_tools_emphasis'}",
+ "{'name': 'Superscript', 'title': 'Superscript', 'css': 'wym_tools_superscript'}",
+ "{'name': 'Subscript', 'title': 'Subscript', 'css': 'wym_tools_subscript'}",
+ "{'name': 'InsertOrderedList', 'title': 'Ordered_List', 'css': 'wym_tools_ordered_list'}",
+ "{'name': 'InsertUnorderedList', 'title': 'Unordered_List', 'css': 'wym_tools_unordered_list'}",
+ "{'name': 'Indent', 'title': 'Indent', 'css': 'wym_tools_indent'}",
+ "{'name': 'Outdent', 'title': 'Outdent', 'css': 'wym_tools_outdent'}",
+ "{'name': 'Undo', 'title': 'Undo', 'css': 'wym_tools_undo'}",
+ "{'name': 'Redo', 'title': 'Redo', 'css': 'wym_tools_redo'}",
+ "{'name': 'Paste', 'title': 'Paste_From_Word', 'css': 'wym_tools_paste'}",
+ "{'name': 'ToggleHtml', 'title': 'HTML', 'css': 'wym_tools_html'}",
+ "{'name': 'CreateLink', 'title': 'Link', 'css': 'wym_tools_link'}",
+ "{'name': 'Unlink', 'title': 'Unlink', 'css': 'wym_tools_unlink'}",
+ "{'name': 'InsertImage', 'title': 'Image', 'css': 'wym_tools_image'}",
+ "{'name': 'InsertTable', 'title': 'Table', 'css': 'wym_tools_table'}",
+ "{'name': 'Preview', 'title': 'Preview', 'css': 'wym_tools_preview'}",
+])
+
+WYM_STYLES = '/static/bootstrap/css/bootstrap.css'
+
+
+#if using tinymce
+CMS_USE_TINYMCE = True
+
+TINYMCE_DEFAULT_CONFIG = {
+ 'plugins': "table,spellchecker,paste,searchreplace",
+ 'theme': "advanced",
+ 'skin' : "o2k7",
+ 'width' : '100%',
+ 'theme_advanced_toolbar_location' : "top",
+ 'theme_advanced_toolbar_align' : "left",
+ 'content_css' : "/static/bootstrap/css/bootstrap.css",
+
+
+}
+
+
#blog stuff
ZINNIA_ENTRY_BASE_MODEL = 'zinnia.plugins.placeholder.EntryPlaceholder'
View
@@ -19,6 +19,9 @@
#url(r'^weblog/', include('zinnia.urls')),
url(r'^comments/', include('django.contrib.comments.urls')),
#(r'^gallery/', include('imagestore.urls', namespace='imagestore')),
+
+ (r'^tinymce/', include('tinymce.urls')),
+
#cms urls
url(r'^', include('cms.urls')),
url(r'^', include('cms.urls', namespace='imagestore'))
View
@@ -12,6 +12,7 @@ django-mptt==0.5.2
django-registration==0.7
django-sekizai==0.5
django-tagging==0.3.1
+django-tinymce==1.5.1b2
django-xmlrpc==0.1.3
html5lib==0.95
imagestore==2.7.0

0 comments on commit 87c7627

Please sign in to comment.