Icons, JavaScript Programming Example of Icons in File Manager

JavaScript Programming Example of Icons in File Manager

If you want to visualize data and create icons in File Manager, use the piece of code below. Note that Webix coding samples are free. They can help you build efficient software solutions..

JS Code

/*
The sample uses an outdated File Manager that is no longer supported. 
To learn about the new tool, visit https://docs.webix.com/desktop__filemanager.html
*/


webix.ready(function(){
  webix.ui({
    view: "filemanager",
    id: "fmanager",
    templateIcon: function(fileObj, common){
      var icon = (fileObj.type == "folder"?"folder":"file");
      return "<span class='webix_icon wxi-"+icon+"'></span>";
    }
  });
  $$("fmanager").load("https://docs.webix.com/filemanager/samples/server/");
});