code
Ajax search PHP Example Part 1
<script language="javascript">
//these script lines can be in a seperate js file
function GetXmlHttpObject(handler){
var objXMLHttp=null;
if (window.XMLHttpRequest){
objXMLHttp=new XMLHttpRequest();
}
else if (window.ActiveXObject){
objXMLHttp=new ActiveXObject("Microsoft.XMLHTTP");
}
return objXMLHttp;
}
xmlHttp=GetXmlHttpObject();
//***************
What do you infer from the following code?
<?php
$str = 'Dear Customer,\nThanks for your query. We will reply very soon.?\n Regards.\n Customer Service Agent';
print $str;
?>
a. Only first \n character will be recognised and new line will be inserted.
b. Last \n will not be recognised and only first two parts will come in new lines.
![Validate my RSS feed [Valid RSS]](http://feedvalidator.org/images/valid-rss.png)