Skip to content
Snippets Groups Projects
Commit 9c9ebe80 authored by dczepierga's avatar dczepierga
Browse files

[#1663462] by dczepierga: Destroy existing instance when trying to replace it

parent d9ef9840
No related branches found
No related tags found
No related merge requests found
-----------------------------
2012-06-15
2012-07-03
New stable release: 6.x-1.x
-----------------------------
......@@ -7,6 +7,7 @@ New features:
[#1514376] by dczepierga: Change ckeditor xss url to be passed through url()
Bug fixes:
[#1663462] by dczepierga: Destroy existing instance when trying to replace it
[#1216096] by michal_cksource: Fix description to "Custom JavaScript configuration" option
[#1594382] by kmcnamee: Wrong instructions for configuring CKFinder
[#1397812] by dczepierga: External plugins not work on ckeditor_basic.js loading method
......
......@@ -84,12 +84,18 @@ Drupal.ckeditorInit = function(textarea_id) {
if (CKEDITOR.loadFullCore) {
CKEDITOR.on('loaded', function() {
textarea_settings = Drupal.ckeditorLoadPlugins(textarea_settings);
if (CKEDITOR.instances[textarea_id]) {
CKEDITOR.instances[textarea_id].destroy(true);
}
Drupal.ckeditorInstance = CKEDITOR.replace(textarea_id, textarea_settings);
});
CKEDITOR.loadFullCore();
}
else {
textarea_settings = Drupal.ckeditorLoadPlugins(textarea_settings);
if (CKEDITOR.instances[textarea_id]) {
CKEDITOR.instances[textarea_id].destroy(true);
}
Drupal.ckeditorInstance = CKEDITOR.replace(textarea_id, textarea_settings);
}
};
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment