XmlHttpRequest AJAX not returning message from COMET server

I have the following COMET client javascript code:
function getResponse() {
document.getElementById("_receivedMsgLabel").innerHTML += "getResponse() called.<br/>";
if (receiveReq.readyState == 4 || receiveReq.readyState == 0) {
receiveReq.open("GET", "http://L45723:1802?callback=testcallback", true); //must use this URL at work.
receiveReq.onreadystatechange = handleReceiveMessage;
alert("handleReceiveMessage assigned to onreadystatechange event.");
receiveReq.overrideMimeType("text/x-json");
receiveReq.timeout = 100000;
var currentDate = new Date();
var sendMessage = JSON.stringify({
SendTimestamp: currentDate,
Message: "Message 1",
Browser: navigator.appName,
OriginUrl: document.URL
var sendMessage = "SendTimestamp=" + currentDate + "&Message=Message1&Browser=" + navigator.userAgent;
alert("JSON message created. About to send...");
receiveReq.send(sendMessage);
alert("Message sent.");
//function for handling the return message from Comet
function handleReceiveMessage() {
document.getElementById("_receivedMsgLabel").innerHTML += "Status=" + receiveReq.status;
document.getElementById("_receivedMsgLabel").innerHTML += "responseText=" + receiveReq.responseText;
if (receiveReq.readyState == 4 && receiveReq.status == 200) {
document.getElementById("_receivedMsgLabel").innerHTML += "Message received!<br/>";
var status = receiveReq.status;
var txt = receiveReq.responseText;
document.getElementById("_receivedMsgLabel").innerHTML += txt + "<br/>";
mTimer = setTimeout("getResponse();", 0);
getResponse();
The GET request is sent and received by the COMET server, which sends the response back when I choose to. The handleReceiveMessage() function is called, but the message the server sent is not in the xmlHttpRequest.responseText property.
Why?

I suggest continuing the discussion in your thread on mozillaZine, since this site focuses more on end-user support.
[http://forums.mozillazine.org/viewtopic.php?f=25&t=2480435 xmlHttpRequest object - mozillaZine Forums]

Similar Messages

  • Phone not deleting messages from the server

    Please help! My Blackberry Curve 9360 is not deleting messages from the server meaning that, after returning home from a week working away, i've still got a few hundred messages to wade through on my PC.
    I receive e-mails on the PC via Outlook Express. I've clicked on 'tools', 'accounts' then 'advanced' to ensure that the box for 'leave a copy of the message on the server' is unchecked i.e. messages sould be being deleted from the server when prompted to by the phone but this is not happening. Not sure what else to try or perhaps there was something i did / didn't do during the set-up of the phone.
    Any guidance would be much appreciated.
    Thanks in advance,
    Barry.

    Hello,
    Please check this KB:
    KB05133 Email reconciliation features for the BlackBerry Internet Service
    All reconciliation capabilities between your BB and your email SERVER are governed by that KB. So, even if you set the other settings (e.g., "Delete On") correctly, they will be irrelevant if your email service does not support it (as per that KB).
    Further still, reconciliation between your email SERVER and your PC CLIENT software are something completely separate. Only in a very few circumstances (e.g., IMAP) does (for instance) Outlook reconcile items deleted at the Server down to the PC Client.
    Good luck!
    Occam's Razor nearly always applies when troubleshooting technology issues!
    If anyone has been helpful to you, please show your appreciation by clicking the button inside of their post. Please click here and read, along with the threads to which it links, for helpful information to guide you as you proceed. I always recommend that you treat your BlackBerry like any other computing device, including using a regular backup schedule...click here for an article with instructions.
    Join our BBM Channels
    BSCF General Channel
    PIN: C0001B7B4   Display/Scan Bar Code
    Knowledge Base Updates
    PIN: C0005A9AA   Display/Scan Bar Code

  • My messages are not being deleted from the server

    Hi,
    Mail is not removing messages from the server. Every now and than I have to remove messages from my server manually. I went through all the settings ... it works as intended on 2 out of 3 machines ... am I missing something? I can use "delete now" in Mail preferences ... not a big deal, just a nuisance.
    Thanks, Stephan

    Are the Mail settings sticking between reboots on that one Mac?

  • IMAP and deleting messages from the server

    Anyone else trying to use IMAP in the default mail app and seeing that messages deleted locally are not removed from the server?
    I found a lot of posts about this issue on older Android versions and devices, but nothing for the Bionic yet.
    And unlike for POP accounts, there is not an option in the settings to turn this on. IMAP is all about keeping messages and folders in sync between multiple clients, so this is an annoying bug.
    I have been using K-9 as a work around, but I'd rather not use two different mail programs, and don't like the look/feel of K9 as much either.

    DCZim,
      Are you using IMAP or POP?  Also, are you using a popular public IMAP service like GMail, MSN, etc. that can be "auto configured" without having to manually enter the server name?
      Per Google the IMAP bug (which has been fixed some time ago in the Android Mail app but not yet in Motorola's Blur mail app) is triggered by visiting the incoming server settings for the account.
      IMAP's entire purpose it to keep everything in sync between multiple devices/clients.  If you want to delete messages on your phone without deleting them from the server, you should use POP3 instead of IMAP and ensure you have the client configured to NOT remove messages from the server when deleted locally and to always "leave a copy of message on the server".  This is a general concept of POP3, nothing specific to the Bionic, Blur, or Android.

  • "This message has not been downloaded from the server" - Multiple devices all using Exchange Active Sync

    We are having this issue across multiple IOS devices ranging from IOS version 5.x up to the latest 6.1.2. Many (not all) emails sent to the devices are unreadable and simply state: "This message has not been downloaded from the server". Microsoft believes this to be some sort of bug with the IOS devices in the way they are handling the SSL encryption.
    Facts:
    - Devices are connected to an Exchange 2010 SP1 Rollup 6 via Active Sync (No POP3, IMAP or SMTP)
    - issue occurs on multiple IOS devices within the organization ranging from IOS 5.x up to the latest 6.1.2
    - Issue occurs on both external cellular data and internal wireless networks
    - Not all emails sent to the devices result in the error, but issue does tend to occur more frequently from certain senders/domains
    - Using the same user account on an android phone does not result in an issue (even when receiving the exactly same email that has been sent to the IOS devices)
    - Closing mail app / rebooting device does not resolve the issue
    - Doesn't appear to matter what the mesage format is (can be html, plaintext, etc)
    - Spent nearly 7 hours with Microsoft going through the Exchange server configuration and looking for possible causes. None have been found and all testing indicates things are setup correctly.
    - This is not a case of Issue 2.3 listed here: http://support.microsoft.com/kb/2563324 (verified by Microsoft Support)
    - If we disable SSL on the IOS device and connect via plain HTTP the messages are displayed correctly!
    - If we use a different SSL certificate, the issue still occurs - so not a problem with the original cert.
    Does anyone have any suggestions on what would cause this? Does the ISO devices have any sort of log that would indicate why it's reporting this error? The current error is pretty unhelpful.

    GFI Have a solution for this problem. It is to do with iOS implementation of reading the message headers when SPF compliance modifications are made by GFI.
    http://kb.gfi.com/articles/SkyNet_Article/Error-This-message-has-not-been-downlo aded-from-the-server-when-downloading-messages-to-an-iOS-device?retURL=%2Fapex%2 FSupportHome&popup=true

  • I updated my iphone 4S with iOS 6.1.3 and now my e-mails say, "This message has not been downloaded from the server".  We have an Exchange server at work.  ??

    I updated my iphone 4S with iOS 6.1.3 and now I cannot retreive or send my e-mails.  We have an Exchange server at work.  I still receive the e-mails on all my devices just fine and I can see the subject headings & a small portion of the body of the e-mail, but when I open the e-mails there is no body and it reads, "This message has not been downloaded from the server".  Very aggrevating and is not helping my business at ALL!!  Same has happened with both iPads we own now. 

    Delete then add back the exchange acct on each device.

  • "This message has not been downloaded from the server"

    Hello, Ever since ive had an iPhone and have used Edge to open a resaonably sized email i usually get "This message has not been downloaded from the server". Im sure this has to do with the slow Edge network timing out. How do you correct this if there is no "Download Now" button. The only solution I have found was to force quit the Mail App (Hold Home button for 6 seconds) and go back in and pray that it downloads without timing out.

    There was a thread on this yesterday that stated that if there is more message it may take four to five minutes to download the entire message and/or attachments.
    One poster even said that it has taken him over 30 minutes in some cases.
    I have this same problem on some email and on others the entire email is downloaded, including any attachments. Since there is no communication put out by Apple regarding this anomaly, it is hard to say whether this a an Apple or provider, i.e., Google or Yahoo.

  • Mail is not downloading messages from two accounts but the messages are in the server.

    Hello, I'm having this problem. Mail is not downloading messages from two accounts. I don't know why but there're two accounts working so bad. If I click with the right button on the account and click to see the account details, I can see the messages on the server but not in inbox. I made a sync with this account and my iphone and then the iphone downlad the messages with out problems. Not my imac at work or my imac at home... what can be wrong?
    Thanks.

    For Gmail, this is normal, there is nothing you can do about it -- just type Mail AND Gmail in the search box to see threads discussing how Gmail works.
    As for the other accounts, this shouldn't happen. I wonder if what you're seeing is just that Mail is ignoring this setting for mail that was already on the server when you started using it. I've seen something like this happen when playing with that setting, e.g. changing it from "After one day" to "After one week". Mail would just ignore messages that fell in the timeframe where the two settings could interfere and I didn't notice it until some time later, when Mail "forgot" those messages had already been downloaded and, being faced with them again, dutifully downloaded them as if they were all new.
    I believe that, if you leave the setting however you wish and stop playing with it, then Mail shall correctly process any mail that arrives from now on. In order to manually delete old messages that Mail seems to be ignoring, you can invoke the Account Info window (this is probably what you meant when you said "I can delete messages individually"; if that's not the case and want more info on this, just ask).

  • Error message: The message from - has not been downloaded from the server.

    "The message from Doug Peets <[email protected]> concerning “Fires” has not been downloaded from the server. You need to take this account online in order to download it."
    I get this error message several times per day, even on my Sent mail box, and Drafts, which clearly does not need to be downloaded (does it?). It usually happens when I switch mailboxes, from In to Sent, to Drafts and so on.
    I have 100 Gigs of hard drive with 90 Gigs free. I have about 6,700 saved incoming e-mails and 4,700 sent e-mails.
    TRhis has only started happening in the last couple months. How do i get rid of it? Is it because i have too many saved e-mails?
    When I shut down Mail and re-open it, the messages display properly, but this is a nuisance several times per day.
    Thanks,
    Doug.

    Thanks. I moved half of the messages to a new mailbox "old e-mails", then copied that to a new folder on my desk top, which saved it with a .mbox suffix, then emptied the Old e-mails mailbox in Mail. I will repeat this every three months.
    So far, so good.
    thanks for your help.
    Doug Peets

  • "mail" will not dowload messages from server

    My "mail" program has been working fine until today. Now it will not download my messages from the server. I have made no changes what so ever in the settings and I have reviewed them & they seem ok. Being a rather new (6 mo) to mac I have no idea where to start. I have a duo intel 20 and when I switch to Outlook Express in windows no problem. Any ideas would be appreciated. I have it set to check for mail every 5 min. Also I can send ok. Jim Johnston

    Hi Jim
    I have a similar problem. Mail stopped receiving messages from the server on Tuesday afternoon around 4pm. I can see the messages on the server via a webmail page, so I know messages are there.
    Strange twists:
    1 if i rebuild the inbox, Mail will fetch all the mails from the server - but only those dating from before c4pm last Tuesday - the later ones stay on the server and are not fetched
    2 ditto if I trash the preference file for received mail (as recommended in other posts) - again, it will fetch all mails up until c4pm on Tuesday, and no later
    3 ditto if I trash the entire account, and then add a new account with the same settings - again, it will fetch messges only from before c4pm on Tuesday
    4 my dotmac mails are set to forward to the server/account in question. Mail will fetch all of these successfully from the server - even those dating from after c4pm on Tuesday - so what am I to make of that?! The account and server are identical to the one in points 1-3 above.
    I have (of course) contacted my ISP and they are mystified - they said they'll get back to me, but that was 36 hours ago and no news yet...
    I read somewhere that filling the HD can have weird knock-on effects on Mail. My HD did temporarily fill as I was importing my iTunes library from my backup disk (I got the warning that the library wouldn't fit, so I cancelled the entire operation and actually imported nothing at all). I still have more than 6GB free on the HD.
    I can send mails successfully using the account/server/ISP in question.
    Can anyone help?

  • Apple mail not uploading messages from server

    i've got a weird problem - about a week ago, my apple mail program stopped uploading messages to one of my emails accounts. i've been getting messages to that account, and when i right click on the account, apple mail shows me that i have like 100 + unread messages on my pop server, but for some reason, it isn't uploading the messages so that i can access them.
    i've spent nearly 2 hours troubleshooting. i even deleted the whole account and made it again, and it did the same thing. this makes me think there is something with my email host or something.
    any ideas?

    When you say “uploading” you actually mean “downloading”, right?
    Sometimes messages left on the server clog up the account there, or Mail chokes on a message it cannot download and that prevents it from downloading the rest as well. Solving this problem will probably require deleting one or more messages from the server. What are your Preferences > Accounts > Advanced > Remove copy from server settings for this account?
    You may tell Mail to remove from the server all the messages that have already been downloaded doing Preferences > Accounts > Advanced > Remove now. Alternatively, you may use the Account Info window to remove specific messages from the server. And if the account allows web access, you may also remove messages from the server that way.
    Try first removing from the server messages that have already been downloaded. If that doesn’t work, you’ll probably have to delete the first message not downloaded yet. You may want to try to download those messages with another mail client such as Thunderbird first, to avoid losing them -- and use Eudora Mailbox Cleaner to import them back into Mail afterwards if you wish.

  • Why can't I read my emails from my iPad mailbox on my iPad today?Each message is replaced by the comment "This message has not been downloaded from the server."thank you

    Why can't I read my emails from my iPad mailbox on my iPad today?Each message is replaced by the comment "This message has not been downloaded from the server."thank you

    In which case, clearly communicating the intent would have been a better solution.  The steps do apply.  A more appropriate response would have been "tried that, no change".
    Regardless of whether they fixed the problem or not, they do apply.
    If English is not your native language, I would strongly encourage you to post in your native language going forward.
    If basic troubleshooting has not resolved the issue, the next step is to take the device to Apple for evaluation.

  • Searched email showing "The message has not been downloading from the server."

    I have Exchange email setup on my iPad. When I search for an email that has a large attachment (15mb PDF) the results show two identical emails. If I click on the first one it says "This message has not been downloaded from the server." The second email seems to open correctly. Closing the Mail app and opening back up doesn't fix the issue. Neither does rebooting iPad. Anyone have any idea why the search is showing multiple emails and why they won't download correctly?
    --Brian

    I am the IT department. Seems to be an issue with the search showing the email locally and server side, so it shows up twice. If I open the email that is server side, it has an issue opening the email again unless I try several times. I'm working with Apple now so hopefully they can help.

  • Messages not being deleted from POP server...

    ...at least not quickly. I have Mail set up to delete messages from the server "When moved from Inbox". I assume deleting a message is included in this definition. Yet I can delete a message and the message won't be removed from the server for hours, if at all. I'll connect to the server multiple times in the interim, giving Mail a chance to update the server, but no dice.
    I'll even empty the Trash in Mail and it still won't update on the server. Everything else seems to function in Mail and I have the problem on several different Macs with different POP accounts. Any ideas?
    EDIT: I just deleted a bunch of old messages manually by using the Get Account Info interface. They successfully deleted, but newer ones which have been deleted and emptied from Mail (but not removed manually) still remain.

    I just responded to another question that was similar to this one, so I have another suggestion or two..
    Godaddy supports the automatic forwarding of email to any other email account. For backup purposes, I have my domain/email provider, http://www.fidomains.com , automatically forward any emails to a Gmail account. This allows me to have a backup to all my emails. Works Great! Godaddy will work well for that also.
    Godaddy configuration info:
    - Incoming mail server: imap.secureserver.net, Turn on SSL support and use port 993 for Godaddy. (Incoming)
    - Outgoing server: smtpout.secureserver.net, SSL support and port 465 for Outgoing.
    gnormal
    http://blog.androidance.com

  • "mail has not been downloaded from the server" messages......

    About 2 weeks ago I started seeing "mail has not been downloaded from the server" messages popping up when I attempt to both new mail and e-mails that I have already read. I usually don't have any problems when I first launch the program, but after a few minutes running I get this message when I try to open any e-mail.
    The message from "---" <[email protected]> concerning “RE: S8-04 pps sample package” has not been downloaded from the server. You need to take this account online in order to download it.
    I know that the program is running online because it continues to show me new e-mails that come in.
    What should I do?

    Your OS detail provided indicates you are running 10.4.7 and Sasso's OS detail provided is 10.3.9.
    The MBOX Breaker script does not work with Tiger mailboxes which are different from the mailbox structure used with previous Mail.app versions and the link you provided includes instructions for Jaguar or Panther Mail, not Tiger Mail. And depending on the size of the mailbox with Jaguar or Panther Mail, the MBOX Breaker Script may not be required.
    If you are getting this message with Tiger Mail, this indicates you upgraded to Tiger from Jaguar or Panther on this Mac.
    If so and if this Sent mailbox is for a POP type account, using the Finder go to Home > Library > Mail > this POP account named folder (named by the user name and incoming mail server for the account) > Sent Messages.mbox.
    List all file and folder names available within the Sent Messages.mbox folder.

Maybe you are looking for

  • Changing my Apple ID on my iCloud on iMac too ....

    Hi, I've changed my Apple ID on Apples pages, because I needed a new e-mail adress. Unfortunately, my iCloud preferences on my iMac with OSX.8.3 still clings to my old e-mail adress, as does Apple Store, and there seems to be no way to change the App

  • IPod nano won't turn on or be recognized in iTunes or Vista

    We recently upgraded to Windows Vista, so I downloaded iTunes 7.2, then plugged in my ipod which was working fine, then it said it had to be updated, but first I needed to update something in windows vista. So I updated Vista and also looked in the h

  • Incrementing the URL's ID in JavaScript by clicking a button

    Hello Everyone, I want to Incrementing the URL's ID in JavaScript by clicking a button on the Page in a Content Editor Web Part. I already added the button, but it doesn't incrememnt the ID for the URL. Help will be appreciated. Thatnks. Mike Michael

  • Problem reading DVD-RW on my Macbook

    Hi, I am trying to watch a home movie that was saved onto a DVD-RW disk by one of these stand alone DVD players. My dad took the movie through the machine to write it to DVD. But when I insert it into my Macbook it can't read the disk. The message yo

  • DPMBackup.exe -replica not creating anything in the Shadow Copy folder

    I thought I had this issue resolved in a question I asked earlier. When I run dpmbackup.exe -replicas on my DPM server it says that it was successful for each item. This DPM server only backs up our Exchange 2010 DAG. However, when I go to the volume