This is my Ajax function. It is functioning correctly, however after the function is called, it returns a response containing HTML tags and required text.
Response in value variable "
<br/>
<font size='1'>
<table class='xdebug-error xe-notice' dir='ltr' border='1' cellspacing='0' cellpadding='1'>
<tr>
<th align='left' bgcolor='#f57900' colspan="5">
<span style='background-color: #cc0000; color: #fce94f; font-size: x-large;'>
( ! )
</span>
Notice: Undefined index: raw_id in C:\wamp\www\ajax\jsvarupdat\remote.php on line
<i>
3
</i>
</th>
</tr>
</table>
< /font>
Danial"
Required in value variable
"Danial"
function call_funct(str){
if (str=="")
{
document.getElementById("scat").innerHTML="";
return;
}
if (window.XMLHttpRequest)
{
xmlhttp=new XMLHttpRequest();
}
else
{
xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
}
xmlhttp.onreadystatechange=function()
{
if (xmlhttp.readyState==4 && xmlhttp.status==200)
{
value = xmlhttp.responseText;
}
}
xmlhttp.open("post","remote.php?raw_id"+str,true);
xmlhttp.send();
}