Reputation: 16085
I need to compare two strings, containing HTML text. The test should return true if the html strings are equivalent, i.e. differ only in whitespace and comments.
Is there any module that can be used for this task?
Upvotes: 4
Views: 264
Reputation: 71969
There's this wrapper around HTMLTidy. HTMLTidy allows you to suppress comments and normalize formatting, etc., so that should do the trick.
Upvotes: 4