博文

ASP.NET AJAX练习一(2007-08-03 16:51:00)

摘要:页面代码: <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default2.aspx.cs" Inherits="Default2" %> <!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 runat="server">
    <title>无标题页</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <asp:ScriptManager ID="ScriptManager1" runat="server">
        </asp:ScriptManager>
    <asp:Button ID="Button1" runat="server" Text="Button" OnClick="Button1_Click" />
        <asp:TextBox ID="TextBox1" runat="server"></asp:TextBox></div>  
    </form>
</body>
</html&g......

阅读全文(2265) | 评论:0

我的第一个AJAX程序(2007-04-28 15:31:00)

摘要:第一个页面: <%@ Page Language="C#" AutoEventWireup="true" CodeFile="AJAX.aspx.cs" Inherits="AJAX" %> <!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 runat="server">
    <title>AJAX</title>
        <script type ="text/javascript" language ="javascript" >
        var req; //定义变量,用来创建xmlhttprequest对象
        function creatReq() // 创建xmlhttprequest,ajax开始
        {
            var url="AJAXSERVER.aspx"; //要请求的服务端地址
            if(window.XMLHttpRequest) //非IE浏览器,用xmlhttprequest对象创建
          &......

阅读全文(2376) | 评论:0