473,773 Members | 2,334 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

AJAX Style processing icon

I'm experimenting with using a AJAX style "processing " icon. The
process I'm running in the background with xmlHttp is intensive and
takes a 5--10 secs to complete. Instead of my processing icon
appearing in the page, the page just freezes during the process until
it's finished. Is this the best way to display this kind of icon?
What can I do so this works right? Thanks

function stateChanged()
{
if (xmlHttp.readyS tate == 0)
{
document.getEle mentById("lblRe sults").innerHT ML = "<img
src='mozilla_bl u.gif' alt='loading..p lease wait'>"; //loading
}
else if(xmlHttp.read yState == 1)
{
document.getEle mentById("lblRe sults").innerHT ML = "<img
src='mozilla_bl u.gif' alt='loading..p lease wait'>"; //loaded
}
else if(xmlHttp.read yState == 2)
{
document.getEle mentById("lblRe sults").innerHT ML = "<img
src='mozilla_bl u.gif' alt='loading..p lease wait'>"; //interactive
}
else if(xmlHttp.read yState == 3)
{
document.getEle mentById("lblRe sults").innerHT ML = "<img
src='mozilla_bl u.gif' alt='loading..p lease wait'>";
}
else if (xmlHttp.readyS tate==4 || xmlHttp.readySt ate=="complete" )
{
document.getEle mentById("lblRe sults").innerHT ML = "";
<span id="lblResults " name="lblResult s"></span>

Apr 13 '07
10 8010
VK
On Apr 16, 7:12 am, "-Lost" <missed-s...@comcast.ne twrote:
JavaScripters should just rely on an existing library instead of learning the proper
way in which to do something?
AjaxRequest is well documented, so one is welcome to study what, how
and why is being made:
http://www.ajaxtoolbox.com/request/source.php

About the "learning curb":

Everything has its time and its place. Some people prefer the
practical learning, so they take a rather complicated task and hit the
wall until it's working - by obtaining the necessary knowledge on the
go from available sources. If OP decided to learn JavaScript over
making a well working ajaxoid then it's fully OK. If OP needs a
working interface right now for a live project then the "learning
curb" may take several months with all oops reported by frustrated
customers and not by an in-house QA. That can become a way too
expensive learning experience.

1) run-time error on reading XHR property after network errors
(despite status=400)
2) send null or "" for GET sensibility for some UA versions
3) GET request length limit on different IE versions
4) multiple async requests caveats which would be a separate nested
list right here

How much time does it take to simply _arrive_ to these questions out
of foggy error reports from your customers?

In this respect AjaxRequest is not really a "library" like say
prototype.js
It is merely a sophisticated interface over all kind of bugs, under-
implementations and limitations of different IXMLHTTPRequest/
XmlHttpRequest implementations .

Apr 16 '07 #11

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

Similar topics

1
16513
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 - microlink pattern tutorial : A microlink is a link that opens up
10
4863
by: trpost | last post by:
I am using ajax / php where I am looking up some info from the database and populating a select list dynamically, however I am running into some sort of size limitation with the ajax.response object. If the string I am passing to javascript from php is too large javascript does not get it all the data. The magic number appears to be 6123 characters, anything below that it works fine, anything above and if I alert the ajax.response, I see...
7
3620
ak1dnar
by: ak1dnar | last post by:
Hi, I got this scripts from this URL There is Error when i submit the form. Line: 54 Error: 'document.getElementbyID(....)' is null or not an object What is this error. Complete Files
1
1990
by: JWHIT | last post by:
I created a map application which works fine with regular aspx and a meta refresh. I would like to have the map itself update independently using ajax. (Sorry on the long post, I just started using ajax. This is on an IIS server and all ajax has just been downloaded and installed and functions with simple ajax web pages) The map worked fine except the original script in C# uses a response.write: (ie) Response.Write("<form...
1
1878
by: bdbeames | last post by:
I have a page with google maps up and running. When a user clicks on a location from the map I would like to populate a drop down with data from the database related to that location. I have it up and working wonderful. Well that was what I thought until I tried it is IE. All that I get is an empty drop down. I know the problem is related to filling the element with the xmlHttp.responseText, but no matter how many solution I have tried as...
4
1981
by: slebetman | last post by:
On Jun 5, 9:36 pm, sheldonlg <sheldonlgwrote: You can of course use closure to pass the required parameter: var hideIt; // the variable you wish to pass ajax.onreadystatechange = function () { if (ajax.readyState == 4) { if (hideIt) {// here you can use the variable..} } }
22
1695
by: sheldonlg | last post by:
I am looking for a clean solution to a problem that I solved in, what I call, a "dirty" way. Here is what I want to do. I have a dropdown list. Clicking on an item in the dropdown list invokes an AJAX call that gets data which populates the entire lower part of my screen. It does this with an innerHTML for the div tag that holds all of this. This works fine. I also have an "Edit" button that I want to show next to dropdown list,...
10
7421
by: dkyadav80 | last post by:
<html> /// here what shoud be java script for: ->when script run then not display all input text field only display selection field. ->when user select other value for institute only this field display not display degree text field ->when user select other value in the selection field for degree then text field display and wise versa //// <bodly> <table>
3
1900
by: fkhowaja | last post by:
i want to show the property details and there status (APPROVED, REJECTED, PENDING) the whole result is coming through ajax now i want that if i click on Approved icon or Pending icon or Rejected icon (seperate column on webpage for this) the status of property should be updated (become my selected status) through ajax and behind the scene the table of property should also be updated with the selected status. Now the problem is that whole...
0
9621
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10264
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10106
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
10039
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
9914
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7463
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
5355
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
5484
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4012
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

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.