Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion Handling HEAD requests in Chrome
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Ross Bates  
View profile  
 More options Dec 6 2011, 3:27 pm
From: Ross Bates <rba...@gmail.com>
Date: Tue, 6 Dec 2011 12:27:47 -0800 (PST)
Local: Tues, Dec 6 2011 3:27 pm
Subject: Handling HEAD requests in Chrome

Hi all - when making a request using Google Chrome the browser issues a GET
followed by a HEAD.

My page is database driven and this second HEAD request is essentially
running through all the code just as the GET does.

I'm trying to put a before_handler tool in to grab the request and return
headers only using something simple like this

if cherrypy.request.method.upper() == 'HEAD':
return cherrypy.response.headers

Alas, it continues to process the body of the page. This custom tool can
capture and handle HEAD requests when I issue a redirect or raise an error,
but then the browser fails to fully load the page.

Any thoughts/suggestions would be much appreciated.

Best Regards,
Ross


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.