Merge pull request #145 from yakky/fix_merge

Fix ckeditor path issues
This commit is contained in:
Iacopo Spalletti 2014-06-20 09:06:46 +02:00
commit d88a170be4
3 changed files with 4 additions and 4 deletions

View File

@ -65,7 +65,7 @@ class TextPlugin(CMSPluginBase):
We override the change form template path
to provide backwards compatibility with CMS 2.x
"""
ckeditor_basepath = urljoin(settings.STATIC_URL, 'ckeditor/')
ckeditor_basepath = urljoin(settings.STATIC_URL, 'djangocms_text_ckeditor/ckeditor/')
if ckeditor_basepath.startswith('//'):
protocol = 'https' if request.is_secure else 'http'
ckeditor_basepath = '{0}:{1}'.format(protocol, ckeditor_basepath)

View File

@ -57,7 +57,7 @@ $(document).ready(function () {
}, this.options, options);
// add additional plugins (autoloads plugins.js)
CKEDITOR.plugins.addExternal('cmsplugins', settings.static_url + 'djangocms_text_ckeditor/ckeditor_plugins/cmsplugins/');
CKEDITOR.plugins.addExternal('cmsplugins', settings.static_url + '/ckeditor_plugins/cmsplugins/');
// render ckeditor
this.editor = CKEDITOR.replace(container, this.options);

View File

@ -5,7 +5,7 @@
{% endblock %}
{% block extrahead %}
<script src="{% static "djangocms_text_ckeditor/cms/js/modules/cms.base.js" %}"></script>
<script src="{% static "cms/js/modules/cms.base.js" %}"></script>
<script src="{% static "djangocms_text_ckeditor/ckeditor/ckeditor.js" %}"></script>
<script src="{% static "djangocms_text_ckeditor/js/cms.ckeditor.js" %}"></script>
{% endblock %}
@ -21,7 +21,7 @@ $(document).ready(function () {
var container = $(this).attr('id');
CMS.CKEditor.init(container, {{ settings|safe }}, {
'static_url': '{{ STATIC_URL }}/djangocms_text_ckeditor',{% if placeholder %}
'static_url': '{{ STATIC_URL }}djangocms_text_ckeditor',{% if placeholder %}
'add_plugin_url': '{{ placeholder.get_add_url }}',
'placeholder_id': {{ placeholder.pk|unlocalize|default:"''" }},
'plugin_id': {{ plugin_pk|unlocalize }},