comparison examples/tutorial/geddit/lib/ajax.py @ 625:abad7c2ebe15 trunk

GenshiTutorial: implemented AJAX commenting.
author cmlenz
date Fri, 31 Aug 2007 17:01:00 +0000
parents
children
comparison
equal deleted inserted replaced
624:dc657447f352 625:abad7c2ebe15
1 import cherrypy
2
3 def is_xhr():
4 requested_with = cherrypy.request.headers.get('X-Requested-With')
5 return requested_with and requested_with.lower() == 'xmlhttprequest'
Copyright (C) 2012-2017 Edgewall Software