search for: raw_header

Displaying 2 results from an estimated 2 matches for "raw_header".

Did you mean: ram_header
2005 Dec 22
5
How to access request''s raw_header: HTTP hdr sent by browser
...ng to get to the RAW headers sent during a GET request on a page, and couldn''t find where. I''m using webrick. Here are the tries I did to get access to it: class ZController < ApplicationController def info #render :inline => request.inspect #render :inline => raw_header.inspect #render :inline => request_line.inspect #render :inline => req.inspect #render :inline => meta.inspect #render :inline => header.inspect #render :inline => headers.inspect # --> response headers #render :inline => $:.inspect #render :inline =...
2006 Feb 12
0
problem serving files which start with newlines
...:CgiRequest::DEFAULT_SESSION_OPTIONS, data ) print data.string <- linefeeds still there header, body = extract_header_and_body(data) print body <- linefeeds gone [...] end [...] def extract_header_and_body(data) data.rewind data = data.read raw_header, body = *data.split(/^[\xd\xa]+/on, 2) <- probably the problem header = WEBrick::HTTPUtils::parse_header(raw_header) return header, body end -- Posted via http://www.ruby-forum.com/.