Hi
I have a Druapl 7 installation using the CKEditor 3.6.5 library and for the most part, it is running fine. If I add a style that defines a class in the ckeditor.style.js, then the element ends up with a style="undefined"
Ideal setup
{ name : 'Feature Block', element : 'div',attributes : { 'class' : 'content-feature-block' } },
produces unwanted style:
<div class="content-feature-block" style="undefined">
Adding a style
{ name : 'Feature Block', element : 'div', styles : { 'direction' : 'inherit' }, attributes : { 'class' : 'content-feature-block' } },
still has 'undefined':
<div class="content-feature-block" style="direction:inherit;undefined">
Style only - which works as expected
{ name : 'Feature Block', element : 'div', styles : { 'direction' : 'inherit' } },
produces expected result:
<div style="direction:inherit;">
Any ideas on how to fix this?
Thank you for any help
Try this
I don't know if this is still an issue for you.
I had the same problem right now and solved it like this:
For your ideal setup the code should look like this:
{ name : 'Feature Block', element : 'div',attributes : { 'class' : 'content-feature-block', 'styles':'' } }
If you want some styles defined with the 'styles' attribute you can do it like this:
{ name : 'Feature Block', element : 'div',styles:{'direction':'inherit'}, attributes : { 'class' : 'content-feature-block', 'styles':'' } }
Hope that helps,
Jan