Anyone ever done HTML validation of an arbitrary piece of HTML within their RoR app.? Any gems/plugins that would work? Would Hpricot do the trick?
Thanks, Wes
Anyone ever done HTML validation of an arbitrary piece of HTML within their RoR app.? Any gems/plugins that would work? Would Hpricot do the trick?
Thanks, Wes
Anyone ever done HTML validation of an arbitrary piece of HTML within their RoR app.? Any gems/plugins that would work? Would Hpricot do the trick?
Are you perchance looking for something like GitHub - wr0ngway/assert_valid_markup: Fork of assert_valid_markup, sped up by using xmllint locally rather than hitting w3c service ? I've never tried that, but I plan to experiment with putting it into my automated specs if it works well.
Thanks, Wes -- Posted viahttp://www.ruby-forum.com/.
Best,
Here’s my old crack at it. Probably newer code bases that do a better job.
http://github.com/kete/validates_as_sanitized_html/tree/master
Cheers,
Walter
BTW, assert_valid_markup looks to be aimed at functional tests and is about the HTML being standards compliant.