SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Evangelist anjanesh's Avatar
    Join Date
    Jun 2004
    Location
    Mumbai
    Posts
    447
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    AJAX Error when typing fast

    Hi

    I've made a textbox which if you type in, will display a suggested keywords box just below it.

    Problem is when typing in too fast. When I hit s and then t, it works fine. But when I enter st together fast enough, the suggest box doesnt show up.

    And I seem to get this error in my JS Console
    Code:
    Error: [Exception... "Component returned failure code: 0x80040111 (NS_ERROR_NOT_AVAILABLE) [nsIXMLHttpRequest.status]"  nsresult: "0x80040111 (NS_ERROR_NOT_AVAILABLE)"  location: "JS frame :: http://mydomain.com/folder/JsScript.js :: processReqChange_foo :: line 77"  data: no]
    Source File: http://mydomain.com/folder/JsScript.js
    Line: 77
    The line seems to be
    Code:
    if (http_req.status == 200)
    And idea how to avoid this ? Say using a pause-timeer or something ?

    Thanx
    Anjanesh

  2. #2
    SitePoint Zealot
    Join Date
    Jul 2006
    Posts
    151
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    We need to see more of the code involved with this in order to help you out. It may not be exclusively a problem with the line quoted.

    Dave


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •