charset=(charset)
public
Sets the HTTP character set. In case of nil parameter it sets the
charset to
default_charset.
response.charset = 'utf-16'
response.charset = nil
# File actionpack/lib/action_dispatch/http/response.rb, line 264
def charset=(charset)
content_type = parsed_content_type_header.mime_type
if false == charset
set_content_type content_type, nil
else
set_content_type content_type, charset || self.class.default_charset
end
end