delpha delpha - 1 year ago 83
Ruby Question

Display or get the HTTP header attributes in Rails 4

I have an application developed in Rails and I am trying to see the attributes in the HTTP header.

Is there any way to read these attributes? Where are they stored?

Someone mentioned

. Is this correct? I am not able to see any attributes inside this array.

Answer Source

This code solved my question request.env["HTTP_MY_HEADER"]. The trick was that I had to prefix my header's name with HTTP

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download