5

I'm working through my first major Drupal 7 implementation. My users need to create nested HTML ordered lists, with the various styling in Roman, numeric and alpha formats as listed at http://www.w3.org/TR/html401/struct/lists.html#type-values . The current project is taking place on a node of content type "book page."

This install is using CKeditor, which properly shows the various format types in edit mode.

In node view mode, though, the styles disappear, reverting to 1,2,3 format. I found in the Filtered HTML settings the statement "... and CSS are always stripped." Since CKeditor applies style commands to create the formatting method, it seems that Drupal filters them out.

Is there a method to allow styling in node view? I just discovered http://drupal.org/project/css_injector but can't yet determine if it will do what I need.


Found this discussion which appears to be related. http://drupal.org/node/259527

1 Answer 1

3

I recommend using the WYSIWYG Filter module. In the "HTML elements and attributes" textarea there is a list of allowed HTML tags. 'ol' should be present. If it is, add '[class|style]' to it which will make it look like this:

ol[class|style]

Or, you can add @[class|style] to the list to enable the style and class attributes on all allowed html tags.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.