You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sending this through Tidy (5.6 and 5.8) "as is" (the message announced it as <!DOCTYPE html>) resulted in a blank screen being displayed since Tidy was trying to move almost all of the HTML body into the head section due to apparently confusing the above coding as an unclosed <style> section following the fix-style-tags option. Using the "doctype loose" option and disabling fix-style-tags would prevent this from occuring.
Although I'm not a C developer I managed to (re)compile the Tidy sources using a free version of VC 10 and prevent this from happening by inserting a tiny work-around into lexer.c's GetTokenFromStream() implementation of the "case LEX_STARTTAG" section":
[well, tried to use the "bold" style for emphasis but it doesn't work as expected, hence the unexpected asterisks in the code]
This is definitely only a workaround as it will just silently drop the faulty code without comment and - since I'm not familiar enough with Tidy's further processing - may have unwanted side effects in other places or on other code. IOW: I would appreciate someone to pick up this issue and deal with it in a more professional way than I am capable of. Please let me know if I can be of further assistance (like provide the full sample, e.g.).
Thanks in advance
Michael
The text was updated successfully, but these errors were encountered:
Hello everyone,
I'm a new member here but a long time user of (Lib)Tidy and believe the following to be an issue of interest for further inspection:
I've recently been submitted real world samples of script generated HTML mails containing the following coding:
Sending this through Tidy (5.6 and 5.8) "as is" (the message announced it as <!DOCTYPE html>) resulted in a blank screen being displayed since Tidy was trying to move almost all of the HTML body into the head section due to apparently confusing the above coding as an unclosed <style> section following the fix-style-tags option. Using the "doctype loose" option and disabling fix-style-tags would prevent this from occuring.
Although I'm not a C developer I managed to (re)compile the Tidy sources using a free version of VC 10 and prevent this from happening by inserting a tiny work-around into lexer.c's GetTokenFromStream() implementation of the "case LEX_STARTTAG" section":
[well, tried to use the "bold" style for emphasis but it doesn't work as expected, hence the unexpected asterisks in the code]
This is definitely only a workaround as it will just silently drop the faulty code without comment and - since I'm not familiar enough with Tidy's further processing - may have unwanted side effects in other places or on other code. IOW: I would appreciate someone to pick up this issue and deal with it in a more professional way than I am capable of. Please let me know if I can be of further assistance (like provide the full sample, e.g.).
Thanks in advance
The text was updated successfully, but these errors were encountered: