Michael

I have created another set of test pages which create the
XMLHttpRequest object itself and then calls another page and have
managed to get this working on Konqueror 3.5.3 and other browsers - so
may try to put some conditionals into my pages to use AjaxPro where it
can and fall back to creating the objects manually.

my test code is:

test.aspx
-------------
<%@ Page Language="VB" AutoEventWireup="true" CodeFile="test.aspx.vb"
Inherits="test" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd";>

<html xmlns="http://www.w3.org/1999/xhtml"; >
<head id="Head1" runat="server">
    <title>TEST IN PAGE CALL</title>

    <script type="text/javascript">

        var req = null;
        function Initialize() {
            if( window.ActiveXObject ) {
                try
                { return new ActiveXObject("Microsoft.XMLHTTP");
                }
                catch(e)
                {   alert("Error - " + e)
                    try { return new ActiveXObject("Msxml2.XMLHTTP"); }
                    catch(er) {alert(er);req=null;}
                }
            }
            if( window.XMLHttpRequest ) {
                return new XMLHttpRequest();
            }
        }

        function SendQuery(key)
        {
            req = Initialize();
            var url="test_response.aspx?k="+key;

            if(req!=null)
            {
                req.onreadystatechange = Process;
                req.open("GET", url, true);
                req.send(null);
            }
        }

        function Process()
        {
            if (req.readyState == 4)
                {
                // only if "OK"
                    if (req.status == 200)
                    {
                        if(req.responseText=="")
                            alert("NO DATA")
                        else
                        {
                            alert(req.responseText);
                        }
                    }
                    else
                    {

document.getElementById("autocomplete").innerHTML=
                            "There was a problem retrieving data:<br>"
                            + req.statusText;
                    }
                }
        }

    </script>

</head>
<body>
    <form id="form1" runat="server">
    <div>
    <input type=button onclick="SendQuery('test')" value="push me" />
    </div>
    </form>
</body>
</html>


test.aspx.vb
-----------------
Partial Class test
    Inherits System.Web.UI.Page

End Class


test_response.aspx
-----------------------------
<%@ Page Language="VB" AutoEventWireup="false"
CodeFile="test_response.aspx.vb" Inherits="test_response" %>

test_response.aspx.vb
---------------------------------
Partial Class test_response
    Inherits System.Web.UI.Page

  Protected Sub Page_Load(ByVal sender As Object, ByVal e As
System.EventArgs) Handles Me.Load
    Response.Write(Date.Now.ToString("dd MMM yyyy hh:mm:ss"))
  End Sub
End Class


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Ajax.NET Professional" group.

To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]

For more options, visit this group at http://groups.google.com/group/ajaxpro

The latest downloads of Ajax.NET Professional can be found at 
http://www.ajaxpro.info
-~----------~----~----~----~------~----~------~--~---

Reply via email to