mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-06-19 17:38:06 +02:00
when converting HTML 2 Text remove style,head and comment style browser-switch
This commit is contained in:
parent
dc17cfbb47
commit
c00e9756eb
@ -1197,7 +1197,10 @@ class translation
|
|||||||
#print "<pre>"; print htmlspecialchars($_html);
|
#print "<pre>"; print htmlspecialchars($_html);
|
||||||
#print "</pre>";
|
#print "</pre>";
|
||||||
#print "<hr>";
|
#print "<hr>";
|
||||||
self::replaceTagsCompletley($_html,'style');
|
if (stripos($_html,'style')!==false) self::replaceTagsCompletley($_html,'style'); // clean out empty or pagewide style definitions / left over tags
|
||||||
|
if (stripos($_html,'head')!==false) self::replaceTagsCompletley($_html,'head'); // Strip out stuff in head
|
||||||
|
if (stripos($_html,'![if')!==false && stripos($_html,'<![endif]>')!==false) self::replaceTagsCompletley($_html,'!\[if','<!\[endif\]>',false); // Strip out stuff in ifs
|
||||||
|
if (stripos($_html,'!--[if')!==false && stripos($_html,'<![endif]-->')!==false) self::replaceTagsCompletley($_html,'!--\[if','<!\[endif\]-->',false); // Strip out stuff in ifs
|
||||||
$Rules = array ('@<script[^>]*?>.*?</script>@siU', // Strip out javascript
|
$Rules = array ('@<script[^>]*?>.*?</script>@siU', // Strip out javascript
|
||||||
'@&(quot|#34);@i', // Replace HTML entities
|
'@&(quot|#34);@i', // Replace HTML entities
|
||||||
'@&(amp|#38);@i', // Ampersand &
|
'@&(amp|#38);@i', // Ampersand &
|
||||||
|
Loading…
x
Reference in New Issue
Block a user