Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
project
drupal
Commits
c082e1b8
Commit
c082e1b8
authored
May 19, 2008
by
Dries
Browse files
- Patch
#258192
by dww: drupal_html_to_text() doesn't support <strong class='foo'>.
parent
21000956
Changes
1
Hide whitespace changes
Inline
Side-by-side
includes/mail.inc
View file @
c082e1b8
...
...
@@ -272,8 +272,8 @@ function drupal_html_to_text($string, $allowed_tags = NULL) {
$string
=
_filter_htmlcorrector
(
filter_xss
(
$string
,
$allowed_tags
));
// Apply inline styles.
$string
=
preg_replace
(
'!</?(em|i)>!i'
,
'/'
,
$string
);
$string
=
preg_replace
(
'!</?(strong|b)>!i'
,
'*'
,
$string
);
$string
=
preg_replace
(
'!</?(em|i)
((?> +)[^>]*)?
>!i'
,
'/'
,
$string
);
$string
=
preg_replace
(
'!</?(strong|b)
((?> +)[^>]*)?
>!i'
,
'*'
,
$string
);
// Replace inline <a> tags with the text of link and a footnote.
// 'See <a href="http://drupal.org">the Drupal site</a>' becomes
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment