hi this is my page Test1.asp
<html>
<head>
<meta http-equiv="Content-Language" content="en-us">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>New Page 1</title>
<script type="text/javascript">
function Alex()
{
var xmlHttp;
try
{
xmlHttp=new XMLHttpRequest(); }
catch (e)
{
try
{
xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
}
catch (e)
{
try
{
xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
}
catch (e)
{
alert("Your browser does not support AJAX!");
return false;
}
}
}
xmlHttp.onreadystatechange=function()
{
if(xmlHttp.readyState==4)
{
document.getElementById("Alex").innerHTML =xmlHttp.responseText;//Get Google Destination Map
}
}
xmlHttp.open("GET","Test2.asp" ,true);
xmlHttp.send(null);
}
</script>
</head>
<body>
<div id ="Alex"></div>
<label onclick="Alex()" >ssss</label>
</body>
</html>
This is requested page Test2.asp
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>New Page 1</title>
</head>
<body>
<div id="Mathew"></div>
</body>
<script type="text/javascript" >
{
document.getElementById("Mathew").innerHTML='ajax is working';
}
</script>
</html>
In the page (Test2.asp) javascript is not working
How do i call test2.asp to my test1.asp using ajax