Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8545099
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T12:42:54+00:00 2026-06-11T12:42:54+00:00

When we send an XMLHttpRequest, we always hundreds of extra bytes with it. In

  • 0

When we send an XMLHttpRequest, we always hundreds of extra bytes with it. In a normal usage it is good. But when building applications that needs speed, this is not good for reliablility.

function update(){
    var xhr = getXMLHttp(); // Normal catch handler for XHR
    xhr.open("POST", "update.php?r=" + "&chatvslog=" + user, true);
    xhr.send();
window.setTimeout("update();",300);
}

The request over does take all the way from 170 to 360ms to send. The problem is that I need this job done faster.

Is there a way of improving my XMLHttpRequest or doing this another way?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T12:42:55+00:00Added an answer on June 11, 2026 at 12:42 pm

    Polling is a bad workaround that does the job in a small scalle but is not efficient and ugly to implement.

    Modern browsers support WebSockets as a much better way to allow bidirectional communication. With something such as node.js’ Socket.IO you can even use a high-level WebSocket abstraction layer that falls back to whatever is available in the browser – it can use WebSockets (preferred) and techniques such as Flash sockets, AJAX long-polling or JSONp long-polling without you having to care about what’s used.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I send 2 bytes of app data on the socket(blocking) every 10 seconds, but
I'm trying to send an XMLHttpRequest object to my Rails server but the headers
I want to change the XMLHttpRequest send function so that a function is called
We can send (put) single values to send into XMLHttpRequest with Ajax. But how
I'm building a small Chrome extension that must send messages through a POST http
I understand there is a method send for xmlHttpRequest objects, but I've been working
I am developing a Chrome extension that makes XMLHttpRequest's on various sites but I
function text_window() { var xmlDoc; if (window.XMLHttpRequest) { xmlDoc=new window.XMLHttpRequest(); xmlDoc.open(GET,cd_catalog.xml,false); xmlDoc.send(); xmlDoc=xmlDoc.responseXML; }
I Send Iqueryable to a function that is below void Method<T>(ref IQueryable<T> qu) {
I have written an XMLHttpRequest which runs fine but returns an empty responseText. The

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.