Skip to content

Instantly share code, notes, and snippets.

@whoisstan
Created May 30, 2012 18:17
Show Gist options
  • Save whoisstan/2838062 to your computer and use it in GitHub Desktop.
Save whoisstan/2838062 to your computer and use it in GitHub Desktop.
log HTTP headers
logger.warn "*** BEGIN HTTP HEADER DUMP ***"
self.request.env.each do |header|
if header[0].match("^HTTP.*")
logger.warn "#{header[0]}: #{header[1]}"
end
end
logger.warn "*** END HTTP HEADER DUMP ***"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment