About
htree provides a tree data structure which represent HTML and XML data.
Home Page
Feature
- Permissive unified HTML/XML parser
- byte-to-byte round-tripping unparser
- XML namespace support
- Dedicated class for escaped string. This ease sanitization.
- HTML/XHTML/XML generator
- template engine
- recursive template expansion
- converter to REXML document
Usage
Following two-line script convert HTML to XHTML.
require 'htree' HTree(STDIN).display_xml
The conversion method to REXML is provided as to_rexml.
HTree(...).to_rexml
Requirements
- ruby : http://www.ruby-lang.org/
Download
- latest release: htree-0.7.tar.gz (sha256)
development version in CVS repository:
http://cvs.m17n.org/viewcvs/ruby/htree/ or checkout with:
% cvs -d :pserver:anonymous@cvs.m17n.org:/cvs/ruby co htree
Install
% ruby install.rb
Reference Manual
See rdoc/index.html.
License
Ruby's

