From: "David A. Black" Date: 2001-09-04T20:25:57+09:00 Subject: [ruby-talk:20853] Re: Minor cgi.rb question Hello -- On Tue, 4 Sep 2001, Tobias Reif wrote: > Niklas Frykholm wrote: > > > > h = HTML.new('HTML3', [:lower_case, :pretty]) > > h.html { > > h.body { > > h.h1('Larger header') > > h.h2('Smaller header') > > } > > } > > cgi.out(h.to_s) > > > > The #body, #h1 and #h2 methods would append their data to the h object. > > Do you agree or would you rather see something else? Is HTML a good class > > name or would HTMLGeneration be better? > > > XHTML strict would be a cool option. It's the current version of HTML: > > On > http://www.w3.org/TR/html4/ > the link > Latest version of HTML: > http://www.w3.org/TR/html > points to > XHTML 1.0 > > and some XML writer/serializer like NQ could be utilized. > > IE5 and NN6 like XHTML. (with NN4 it's bit of a pain, but very possible) > > There should also be an option for CSS, because in XHTML strict, style > in not anymore in the HTML code, but comes from seperate stylesheets > like CSS. > > It's all fun, and the generated documents can be parsed with any XML > parser, and generally have all the advanteages of being XML. The thing is, though, the CGI library isn't just dedicated to producing (the latest version) of XHTML. So if the HTML outputting part of the library is to be reimplemented under a new name, that name should be more general. David -- David Alan Black usually dblack@candle.superlink.net writing from dblack@saturn.superlink.net