I have to display other site collection list data in root site. I am using REST API call to do that. But I am stuck while fetching 'DocIcon'. Can anyone tell me how can I get it?
Here is my code sample:
var folderUrl = '/sites/docs/Health%20safety%20and%20environment/Emergency%20Response';
var url ="http://sharepoint.com/sites/docs/_api/Web/GetFolderByServerRelativeUrl('" + folderUrl + "')?$expand=Folders,Files";
$.getJSON(url,function(data,status,xhr){
for(var i = 0; i < data.Files.length;i++){
$('<tr>').append(
$('<td>').text(data.Files[i].DocIcon),
$('<td>').text(data.Files[i].Name),
$('<td>').text(data.Files[i].TimeLastModified.substring(0, 10))).appendTo('#records_table');
}
});