Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #81774
| From | Israel Brewster <israel@ravnalaska.net> |
|---|---|
| Subject | Cherrypy - prevent browser "prefetch"? |
| Date | 2014-12-01 11:28 -0900 |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.16468.1417465731.18130.python-list@python.org> (permalink) |
[Multipart message — attachments visible in raw view] - view raw
I don't know if this is a cherrypy specific question (although it will be implemented in cherrypy for sure), or more of a general http protocol question, but when using cherrypy to serve a web app, is there anyway to prevent browser prefetch? I'm running to a problem, specifically from Safari on the Mac, where I start to type a URL, and Safari auto-fills the rest of a random URL matching what I started to type, and simultaneously sends a request for that URL to my server, occasionally causing unwanted effects. For example, I have a URL on my Cherrypy app that updates some local caches. It is accessed at http://<server>/admin/updatecaches So if I start typing http://<server>/a, for example, safari may auto-fill the "dmin/updatecaches", and trigger a cache refresh on the server - even though I was just trying to get to the main admin page at /admin. Or, it might auto-fill "uth/logout" instead (http://<server>/auth/logout), and log me out of my session. While the former may be acceptable (after all, a cache update, even if not strictly needed, is at least non-harmfull), the latter could cause serious issues with usability. So how can cherrypy tell the difference between the "prefetch" and an actual request, and not respond to the prefetch? ----------------------------------------------- Israel Brewster Systems Analyst II Ravn Alaska 5245 Airport Industrial Rd Fairbanks, AK 99709 (907) 450-7293 -----------------------------------------------
Back to comp.lang.python | Previous | Next — Next in thread | Find similar | Unroll thread
Cherrypy - prevent browser "prefetch"? Israel Brewster <israel@ravnalaska.net> - 2014-12-01 11:28 -0900
Re: Cherrypy - prevent browser "prefetch"? sohcahtoa82@gmail.com - 2014-12-01 12:41 -0800
Re: Cherrypy - prevent browser "prefetch"? Nobody <nobody@nowhere.invalid> - 2014-12-02 21:05 +0000
Re: Cherrypy - prevent browser "prefetch"? John Gordon <gordon@panix.com> - 2014-12-02 21:41 +0000
Re: Cherrypy - prevent browser "prefetch"? Nobody <nobody@nowhere.invalid> - 2014-12-03 16:09 +0000
csiph-web