:: Forum >>

AW Ajax in Action

Guys, please check


Ajax response,


Typical response

    <response id="alert_ip" type="script">
        alert("Your Ip is xx.xx.xx.xx");
    <response id="myip" type="element">
        &lt;font color="red"&gt;xx.xx.xx.xx&lt;/font&gt;
    <response id="current" type="script">

        alert("Current time is " + new Date());

Main file,


Only problem is that, as of now it works only in I.E. Firefox on XP (sp2) throws following exception

Error: uncaught exception: [Exception... "Object cannot be created in
this context" code: "9" nsresult: "0x80530009
(NS_ERROR_DOM_NOT_SUPPORTED_ERR)" location: "<unknown>"]

Once it becomes stable, I'll add better demo and documentation. You no longer need to look somewhere else for your Ajax need. With Ajax these widgets will get much much powerful. Isn't it?

Sudhaker Raj
Friday, October 7, 2005
Anyone, had any luck with Firefox?
Sudhaker Raj
Wednesday, October 19, 2005

if (!xml.nodeType) {
var s = "" + xml;

if (window.ActiveXObject)
xml = new ActiveXObject("MSXML2.DOMDocument");
else if(document.implementation)
var parser = new DOMParser();
xml = parser.parseFromString(s, "text/xml");

After wasting hours got another problem

var responseText = responseElement.text; // works in IE
var responseText = responseElement.firstChild.nodeValue; // works in gecko

There was a magical statement (perhaps to fix this) inside browsers/gecko.js in 1.x version but it is commented now in 2.x - Why Alex?

element.__defineGetter__("text", function(){return this.firstChild.nodeValue});
Sudhaker Raj
Wednesday, October 19, 2005

This topic is archived.

Back to support forum

Forum search