473,406 Members | 2,619 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,406 software developers and data experts.

ajax example prob


I am new to Ajax and i found some good tutorials from the net.but when i
downloaded the basic sample examples and try to execute i get the error
"specified file not found", even though the files are placed in the
same folder itself.i checked the whole code again and again but could
not do anything.Can any one please help me out with this.
Is it necessary to have a separate server to execute these examples as
i have just downloaded the examples into one folder and trying to
execute??????
The part of code present in the example is :
function returnXML() {
if (http_request.readyState == 4) {
if (http_request.status==200) {
var xmldoc = http_request.responseXML;
displayContents(xmldoc);
} else {
alert('specified file not found.');
}

Can anyone please help!!!!
Thanks

--
dileep
------------------------------------------------------------------------
Posted via http://www.codecomments.com
------------------------------------------------------------------------

Apr 18 '06 #1
2 2124
Ajax is basically an asynch callback mechanism. You build a method on the
server side that has an attribute that tells the server it will be used as a
"web method" (basic web service folded into the code behind/beside). You then
call that method.

When the "file not found" error shows up (at least in the instances I have
seen), either the method is missing, the Ajax call is aimed wrong or the
project is not compiled.

You can debug to an extent and at least trace enough of what is happening to
eliminate some possibilities.

Having not downloaded the sample in question, I can only guess at what is
happening.

--
Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA

***************************
Think Outside the Box!
***************************
"dileep" wrote:

I am new to Ajax and i found some good tutorials from the net.but when i
downloaded the basic sample examples and try to execute i get the error
"specified file not found", even though the files are placed in the
same folder itself.i checked the whole code again and again but could
not do anything.Can any one please help me out with this.
Is it necessary to have a separate server to execute these examples as
i have just downloaded the examples into one folder and trying to
execute??????
The part of code present in the example is :
function returnXML() {
if (http_request.readyState == 4) {
if (http_request.status==200) {
var xmldoc = http_request.responseXML;
displayContents(xmldoc);
} else {
alert('specified file not found.');
}

Can anyone please help!!!!
Thanks

--
dileep
------------------------------------------------------------------------
Posted via http://www.codecomments.com
------------------------------------------------------------------------

Apr 18 '06 #2
q
Look at my XmlHttp library at...

http://www.davidbetz.net/lib/XmlHttp.js

Which requires...

http://www.davidbetz.net/lib/Events.js

Apr 18 '06 #3

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

Similar topics

4
by: bobzimuta | last post by:
I'm creating a simple AJAX library. It's an object that will return an array containing the response text or xml. I'm trying to find a way to assign the response as a property of the object, but...
2
by: Alex | last post by:
Example uploaded to: http://www.clickatus.com/ajax/ BTW - This is for FIREFOX, won't work in IE. I don't know why but when it is executed the browser still in loading state... Even though...
7
by: Ivan Marsh | last post by:
Hey Folks, I'm having a heck of a time wrapping mind around AJAX. Anyone know of a simple, straight-forward example for pulling a simple query from mysql with PHP using AJAX? As I...
1
by: www.web20developers.com | last post by:
http://www.web20developers.com http://www.web20developers.com/index.php?option=com_content&task=view... Ajallerix : AJAX, simple, fast Web image gallery demo ; at Novell AJAX -...
25
by: meltedown | last post by:
This is supposed ot be an example: http://www.ajaxtutorial.net/index.php/2006/11/30/simple-ajax-using-prototype-part-2/ It says : This example is probably the simplest example you will ever...
2
by: shivendravikramsingh | last post by:
hi friends, i m using a ajax function for retrieving some values from a database table,and display the values in required field,my prob is that the ajax function i m using is working f9 once,but if...
18
omerbutt
by: omerbutt | last post by:
AJAX PROB WITH MULTIPLE RECORDS helo iam having problem in ma code will any body look out an help, i am trying t add sale record in the database and the checkthe quantity of the part slod and...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
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...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

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.