diff -r 5b37998e522e -r 162c1de6545a web/lib/Zend/Controller/Action/Helper/AjaxContext.php --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/web/lib/Zend/Controller/Action/Helper/AjaxContext.php Fri Mar 11 15:05:35 2011 +0100 @@ -0,0 +1,77 @@ +addContext('html', array('suffix' => 'ajax')); + } + + /** + * Initialize AJAX context switching + * + * Checks for XHR requests; if detected, attempts to perform context switch. + * + * @param string $format + * @return void + */ + public function initContext($format = null) + { + $this->_currentContext = null; + + if (!$this->getRequest()->isXmlHttpRequest()) { + return; + } + + return parent::initContext($format); + } +}