473,394 Members | 1,812 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

AJAX XML feeds via Web Service

So ajax is the new black, i've had a couple ideas about how to
implement it. I've alook at ajax.net and few other implementations but
to me they're a bit complex. Maybe it's the way to go to have better
coding.

In the standard case of a dropdownlist, or listbox, that needs to be
filled as the user types (aka google suggest), i thought it might be
best handle the following way.

javascript engine <-> xml request <-> asp.net web service (returns xml)
<-> database

Your javascript engine gets an xml feed from the web service (makes
your javascript engine non-asp.net sepific), and your web service acts
as a layer between your data and the UI. The javascript engine fills
the dropdownlist with the returned xml feed.

Is this the wrong way to picture a AJAX asp.net world? Is it better to
implement an ajax.net style solution?
thanks for the ideas

Nov 19 '05 #1
2 1704
this is correct. the problem is doing the httprequest and parsing the xml
from javascript. this is not built into the language but supplied by the
browser (maybe).

there are two ways to do the request

1) use a iframe with a form and do a submit, or set the src with the
parametes passed on the url
2) use the XMLHTTP component (if it exists). this component started with IE,
but has been added to firefox and other browsers. actually with firefox and
safari, it support webservice calls directly. in IE security settings may
prevent it from running.

then the javascript need to parse the response. there are several options

1) if iframe, render hidden fields with values
2) use XMLHTTP to parse xml response
3) use eval to excute a javascript statement that set the values
4) write javascript code to parse the xml.

it is also possible to use SOAP. for IE use the web behavior, and for others
use the builtin SOAP support.
-- bruce (sqlwork.com)



<sh**********@gmail.com> wrote in message
news:11**********************@g14g2000cwa.googlegr oups.com...
So ajax is the new black, i've had a couple ideas about how to
implement it. I've alook at ajax.net and few other implementations but
to me they're a bit complex. Maybe it's the way to go to have better
coding.

In the standard case of a dropdownlist, or listbox, that needs to be
filled as the user types (aka google suggest), i thought it might be
best handle the following way.

javascript engine <-> xml request <-> asp.net web service (returns xml)
<-> database

Your javascript engine gets an xml feed from the web service (makes
your javascript engine non-asp.net sepific), and your web service acts
as a layer between your data and the UI. The javascript engine fills
the dropdownlist with the returned xml feed.

Is this the wrong way to picture a AJAX asp.net world? Is it better to
implement an ajax.net style solution?
thanks for the ideas

Nov 19 '05 #2
Hy guys!
I just want to share that there are great online tutorials about ajax parsing xml at www.KYNOU.com.
You can find by searching for it (the website is like a search engine but just for tutorials) or you can go right into the Newest Tutorials link.
I hope this helps :)
May 10 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Steve | last post by:
Hi, Please help me with this. I am searching for a web service which can provide all the sites that offer RSS feeds for a given string. For example, if I send a search string "movies" as...
3
by: Bevo | last post by:
We'd like our new site to be able to provide other sites with news through RSS feeds. In our software architecture plan, where do we logically describe this 'subsystem'? Is the RSS feature to be...
5
by: lucyh3h | last post by:
Hi, I am trying to use XMLHttpRequest to do server side validation. I have several fields on a form and a submit button. The submit button has an event assocated with it when clicked. The...
7
by: satishr23 | last post by:
Hi, I am using AJAX to display dynamic RSS feeds in my web page. So on page load i am callin the AJAX function Start_Timer() The body of Start_Timer() is as follows. function Start_Timer() { ...
2
by: kpg | last post by:
I have an AJAX enabled web service consumed by an AJAX enabled web app, given a zip code it returns the city and state. Tested the web service, it works fine. I created a services collection...
9
by: Trapulo | last post by:
Hello, with ASP.NET 2.0 Ajax every unexpected error is managed client-side with a popup that reports the error to the user. In ASP.NET 3.5 this behavor has been changed: how can I have a similar...
7
by: =?Utf-8?B?QmlsbHkgWmhhbmc=?= | last post by:
我们现在遇到一个问题,通过wcf创建的webservice,选择windows service作为宿主,采用java作为客户端调用成功,但是无法使用asp.net ajax调用。...
2
by: tshad | last post by:
I am rewriting my VS.Net code to convert from .net 1.1 to .net 3.5 (VS 2008). Now that Ajax is part of the VS, I was curious if it is better to use Ajax.net or is Anthem still a better bet? I...
6
by: Scott M. | last post by:
What is the version number of AJAX when we talk about ASP .NET AJAX in VS 2008?
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
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...
0
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...

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.