Google News
logo
Symfony - Interview Questions
Which method is used to handle an Ajax request on the server-side?
The following methods are used to handle an Ajax request on the server-side.
if ($request->isXmlHttpRequest()) {   
   // Ajax request      
} else {      
   // Normal request       
}
Advertisement