Sean Chittenden <sean / chittenden.org> wrote in message news:<20020509162429.T37453 / ninja1.internal>...

> *) cgi.rb's behavior of having multiple args per key _is_ correct
> *) a common line that I use is:
> 
>    username = CGI::escapeHTML(cgi['username'].to_s) if cgi.has_key?('username')

the single arg is the common case -- instead of cgi['key'].to_s all
the time, cgi['key'].to_a only when you need it.  I prefer
'convenient' over 'correct'.

~ Patrick