Hi,
I've come across the common problem within AJAX and I can't call a function already on the page that AJAX has dumped another page into. I've tried everything and asked all around the internet with little helpful supply. Other peoples scripts don't work for mine and I couldn't get anything working with eval().

Here's 2 pages:
index.php:
HTML Code:
<html>
<head>
<title>AJAX</title>
<script type="text/javascript">
var xmlhttp=false;
/*@cc_on @*/
/*@if (@_jscript_version >= 5)
// JScript gives us Conditional compilation, we can cope with old IE versions.
// and security blocked creation of the objects.
 try {
  xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
 } catch (e) {
  try {
   xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
  } catch (E) {
   xmlhttp = false;
  }
 }
@end @*/
if (!xmlhttp && typeof XMLHttpRequest!='undefined') {
	try {
		xmlhttp = new XMLHttpRequest();
	} catch (e) {
		xmlhttp=false;
	}
}
if (!xmlhttp && window.createRequest) {
	try {
		xmlhttp = window.createRequest();
	} catch (e) {
		xmlhttp=false;
	}
}
function loadajax(){
xmlhttp.open("GET", "ajax.php",true);
 xmlhttp.onreadystatechange=function() {
  if (xmlhttp.readyState==4) {
  document.getElementById("show").innerHTML = xmlhttp.responseText;
  }
 }
 xmlhttp.send(null)
}
</script>
</head>

<body>
<a href="javascript:loadajax();">Load AJAX Page</a><br />
<div id="show">AJAX will go here</div>
</body>
</html>
ajax.php
HTML Code:
<script type="text/javascript">
function test(){
	alert("This doesn't work!");
}
</script>
<a href="javascript:test();">Click Me</a>
The link doesn't show the alert like it's meant to.
Any help really would be appreciated,
Sephers.