• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

[Ajax] response time is very-very slow

 
ankur rathi
Ranch Hand
Posts: 3830
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am using this auto complete script for displaying suggestions: auto complete.

I read some old post having same sort of issue and found it's because of server side processing, JS merely take time.

But here in my case:


I am alerting server response first and then callig this ac script. Server response is coming in reasonable time (not fast though) but suggestions are getting displayed after a huge time delay. Moreover matchingNames array has only 2-3 values at this time.

What could be the problem?

TIA.
 
ankur rathi
Ranch Hand
Posts: 3830
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
One difference I found is:

They are NOT calling this function on any event:


And I am calling a JS function on onKeyUp event of textbox, that JS function sends Ajax request... and then in callback function, I am calling this actb() function. :roll:
 
Ulf Dittmer
Rancher
Posts: 42968
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Which part (or statement) of the code takes a long (too long) time? What does the actb function do - does the delay get introduced there?
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You probbaly need to make your serverside code faster if it takes a long time.

Eric
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic