def header(options = "text/html")
if options.class == String
@head['Content-Type'] = options unless @head['Content-Type']
else
@head['Content-Type'] = options['type'] || "text/html"
@head['Content-Type'] += "; charset=" + options['charset'] if options.has_key? "charset" if options['charset']
@head['Date'] = CGI::rfc1123_date(Time.now) if options['nph']
@head['Server'] = options['server'] || env_table['SERVER_SOFTWARE']
@head['Status'] = options['status'] if options['status']
@head['Content-Language'] = options['language'] if options['language']
@head['Expires'] = options['expires'] if options['expires']
REMOVED_KEYS.each {|k| options.delete(k) }
options.each{|k,v| @head[k] = v}
end
""
end