Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

dynamic select box - with ajax

 
indu yeturu
Ranch Hand
Posts: 123
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all, am trying to get the values for dropdown box from database and this box has to be added dynamically and should load with values.
--- connecting to servlet , fetching values from database and retrieving in javascript --- up to this part is working fine.

But, when I try to append these in callback() it is not recognizing the variables used in add function. In add() am adding some more textboxes dynamically ...


please help me ...
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Put the callback function inside the add function so if has reference to the local variables.

Eric
 
indu yeturu
Ranch Hand
Posts: 123
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
when i put callback() inside add() it simply shows the req.readyState = 1;
and doesn't do anything
 
indu yeturu
Ranch Hand
Posts: 123
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
and when I try like this..

it is not going inside the callback function.. and pop up the alert box as "Not implemented ".
 
indu yeturu
Ranch Hand
Posts: 123
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
oh!... I got it..... please close this thread..
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic