473,836 Members | 1,568 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

creating a Ajax dynamic list

30 New Member
Hello,
I am new in Ajax. I want to create Ajax dynamic list with ASP and XML. can anybody will help me regarding This.

Thanks in advance..
Mar 27 '08 #1
6 2592
aswath
18 New Member
Hello,
I am new in Ajax. I want to create Ajax dynamic list with ASP and XML. can anybody will help me regarding This.

Thanks in advance..

r u finding problem in sending a request itself or u can get the response however facing problem in creating dynamic list box options........
regards
Mar 27 '08 #2
r035198x
13,262 MVP
Hello,
I am new in Ajax. I want to create Ajax dynamic list with ASP and XML. can anybody will help me regarding This.

Thanks in advance..
What have you done so far?
Mar 27 '08 #3
dasrasmikant
30 New Member
r u finding problem in sending a request itself or u can get the response however facing problem in creating dynamic list box options........
regards
My problem is how to disply individually records in the div element
Mar 27 '08 #4
aswath
18 New Member
My problem is how to disply individually records in the div element
hi dasrasmikant,
div elements??? do u want to create <option> tags dynamically?SO that u can have u resultant data in another combo box... if yes i can send u the code for that....
regards.......
Mar 28 '08 #5
dasrasmikant
30 New Member
hi dasrasmikant,
div elements??? do u want to create <option> tags dynamically?SO that u can have u resultant data in another combo box... if yes i can send u the code for that....
regards.......
Thanks aswath
Actually I want to show the data in a div like in http://www.answers.com/
Mar 28 '08 #6
aswath
18 New Member
Thanks aswath
Actually I want to show the data in a div like in http://www.answers.com/

ur url is aint woriking.
the below code can be used to create dynamic listbox options..
this code ll be useful if i have understood ur question properly.......
Expand|Select|Wrap|Line Numbers
  1. xmlHttp.onreadystatechange=function()
  2.                                             {
  3.                                                 if(xmlHttp.readyState==4){
  4.                                                     status_name = xmlHttp.responseText;
  5.  
  6.  
  7.                                                     if ((status_name=="") || (status_name==null))
  8.                                                         {
  9.                                                             removeOptionLast2();
  10.  
  11.                                                         }
  12.                                                         else
  13.                                                             {
  14.                                                                 removeOptionLast2();
  15.  
  16.                                                                 var col_array1=status_name.split("/");
  17.                                                                 //                        alert(col_array[0]);
  18.                                                                 var part_num1=0;
  19.  
  20.                                                                 while (part_num1 < col_array1.length)
  21.                                                                     {
  22.  
  23.                                                                         var a=document.createElement('option');
  24.  
  25.                                                                         a.text=col_array1[part_num1];
  26.                                                                         a.value=col_array1[part_num1];
  27.  
  28.                                                                         var b=document.getElementById("modify_status_name");
  29.                                                                         try
  30.                                                                         {
  31.                                                                             b.add(a,null); // standards compliant
  32.                                                                         }
  33.                                                                         catch(ex)
  34.                                                                         {
  35.                                                                             b.add(a); // IE only
  36.                                                                         }
  37.  
  38.  
  39.  
  40.                                                                         part_num1+=1;
  41.                                                                     }
  42.  
  43.                                                                 }
  44.  
  45.  
  46.                                                             }
  47.                                                         }
regards
Mar 28 '08 #7

Sign in to post your reply or Sign up for a free account.

Similar topics

0
1743
by: Ex-Em-El | last post by:
I have a problem in creating a dynamic table in the same xml : 1.xml: <?xml version="1.0" standalone="yes"?> <?xml-stylesheet type="text/xsl" href="2.xsl"?> <aaa xmlns="http://tempuri.org/My.xsd"> <ppp> <po>
1
1528
by: Rob Venable | last post by:
Hi, Does anyone know the syntax for creating a dynamic radio button from a Javascript function. I think it's something like: var btn = new radio( some arguments ); but I don't know the arguments or if this is even right. Any help would be appreciated. Thanks
11
11777
by: tara99 | last post by:
I was wondering if can some help me with creating a dynamic list box. I have a combobox with the list of items (item1, item2, item3). item1 has 5 sub items item2 has 10 sub items item3 has 2 sub items I want the size of the list box to change depending on the number of sub items available. I hope this is clear.
2
5696
by: Milsnips | last post by:
hi there, i'm creating a dynamic menu system for a CMS website application. What i am currently doing is the following: in a function called LoadMenu(), i loop through the required db records and add the menus on the fly, however because its not known which folder level the page will be on, i need to use a <asp:hyperlinkcontrol so i can use the navigateUrl="~/...." functionality, whilst still programaticallly creating the...
1
2930
by: empiresolutions | last post by:
Hello fellow code junkies, I am using the "Ajax dynamic list" http://dhtmlgoodies.com/index.html?whichScript=ajax-dynamic-list and i think its the best out there. I have found a compatibility issue maybe one of you can help me out on. In this html i use a text field to collect info. when a user types, *ajax_showOptions()* shows the option perfectly. once an item is selected and i move from the field, *makeRequest()*, my set variable to...
1
4391
by: Allan Ebdrup | last post by:
I have a dynamic list of regular expressions, the expressions don't change very often but they can change. And I have a single string that I want to match the regular expressions against and find the first regular expression that matches the string. I've gor the regular expressions ordered so that the highest priority is first (if two or more regular expressions match the string I want the first one returned) The code that does this has...
2
2178
by: pralhadkulkarni12 | last post by:
Hi, I am a new user of AJAX. I need to generate suggest list for every input given by user as we get in Google. To generate I need AJAX code which will read data following XML file. e.g. <?xml version="1.0" ?> <company> <turnover> <year id="2000">appi</year> <year id="2001">archana</year>
1
3757
by: skyson2ye | last post by:
Hi, guys: I have written a piece of code which utilizes Javascript in PHP to create a three level dynamic list box(Country, States/Province, Market). However, I have encountered a strange problem, and I have spent three days trying to debug but to no avail. Everything is OK when there are only two dependent list boxes, but when adding the third child list box, a problem appears: if I populate the third box only with the value: new...
4
2258
by: raknin | last post by:
Hi, I am creating dynamic list in the server through php and insert it using ajax. for ajax I using the following statement: document.getElementById(list_name_id).innerHTML=xmlHttp.responseText ; until now everything is OK the list is builds correctly. but when I use the document.getElementById(call_list_id).options.value I got an error saing "value is null or it is not an object" It seems that object list ID is null. Although...
0
9671
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10553
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10596
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9382
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7793
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5651
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5829
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4459
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
4021
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.