Default.aspx
代码如下:
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
<!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>
<script type="text/javascript">
function data_insert()
{
var xmlhttp;
if (window.ActiveXObject) {
xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
}
else if (window.XMLHttpRequest) {
xmlhttp = new XMLHttpRequest();
}
else {
alert("您的浏览器不支持ajax,请使用其他!");
}
xmlhttp.onreadystatechange=function()
{
if (xmlhttp.readyState==4 && xmlhttp.status==200)
{
alert("yeah!");
}
}
var no, name;
no = document.getElementById("TextBox1").value;
name = document.getElementById("TextBox2").value;
var url = "Default2.aspx?no=" + no + "&name=" + name;
xmlhttp.open("get", url, true);
xmlhttp.send(null);
}
</script>
</head>
<body>
<form id="form1" runat="server">
<div>
号码:<asp:TextBox ID="TextBox1" runat="server"></asp:TextBox><br />
新闻热点
疑难解答
图片精选