concrete/src/Http/Service/Ajax.php
public function isAjaxRequest(Request $request)
    {
        $result = false;
        $requestedWith = $request->server->get('HTTP_X_REQUESTED_WITH');
        if (is_string($requestedWith) && strcasecmp($requestedWith, 'XMLHttpRequest') === 0) {
            $result = true;
        }

        return $result;
    }
public function isAjaxRequest(Request $request)
    {
        $result = false;
        $requestedWith = $request->server->get('HTTP_X_REQUESTED_WITH');
        if (is_string($requestedWith) && strcasecmp($requestedWith, 'XMLHttpRequest') === 0) {
            $result = true;
        }

        return $result;
    }
public function isAjaxRequest ( Request $ request ) { $ result = false ; $ requestedWith = $ request -> server -> get ( 'HTTP_X_REQUESTED_WITH' ) ; if ( is_string ( $ requestedWith ) && strcasecmp ( $ requestedWith , 'XMLHttpRequest' ) === 0 ) { $ result = true ; } return $ result ; }
Check if a request is an Ajax call.

@param Request $request

@return bool
Check if a request is an Ajax call .