Pradeep
Pradeep

Reputation: 3

NetworkError: Failed to execute 'send' on 'XMLHttpRequest' with Chrome Browser - Ext JS

I am getting an error on logging out from an application via Chrome browser only.

Chrome browser version 86.0

Blocked alert('Uncaught NetworkError: Failed to execute 'send' on 'XMLHttpRequest': Failed to load 'https://host-name/web/base/logout?id=40dee37f-cf1d-40f9-b01d-2a414d446a77&tenant=ABC&isFrameMode=true&_dc=1602665141328': Synchronous XHR in page dismissal. See https://www.chromestatus.com/feature/4664843055398912 for more details.. line: 1. url: https://hostname/web/base/abc/app.js?_dc=20161213063112') during unload.

Code that is being used to logout from Application :

var vRequest = { url: vUrl, async: false },
Ext.Ajax.request(vRequest);

Have tried changing the async attribute value from false to true but now the request status is being displayed as canceled in Developer Tools.

Upvotes: 0

Views: 6622

Answers (1)

mcg1103
mcg1103

Reputation: 688

The problem is not the ajax call. The problem is the call is, based on the error your are getting, happening during an event that is no longer allowed, beforeunload, unload, pagehide, visibilitychange... etc

Here are some alternate ways to return data to the server on logout.

Upvotes: 2

Related Questions