When processing an HTML page with inline CSS, filter_xss() is unable to properly handle the direct descendant selector ' > '. When used through drupal_html_to_text() the result is the inline CSS is partially included in the plain text message.

Comments

mfb’s picture

Version: 6.9 » 6.x-dev

I also hit this issue with a piece of HTML inside a CSS comment, as seen in http://cvs.drupal.org/viewvc.py/drupal/contributions/modules/cck/theme/c...

/* CSS overrides for Views-based autocomplete results.
  - #autocomplete uses "white-space:pre", which is no good with
    Views' template-based rendering
  - Field titles are rendered with <label> in default templates,
    but we don't want the 'form' styling it gets under .form-item
*/
.form-item #autocomplete .reference-autocomplete {
  white-space:normal;
}

After <label> the rest of the contents of the <style> element are returned as text (in this case it's mimemail module that moves the CSS file into a <style> element, in case you're wondering).

multiplextor’s picture

Status: Active » Closed (won't fix)

Closed. The reason: expired.