$file_extension = "pdf"; $icon_path = ilUtil::getTypeIconPath($file_extension); echo "";
$file_extension = "docx"; $icon_path = ilUtil::getTypeIconPath($file_extension); echo " Download Document";This example retrieves the path to the icon file for a Word document, and then displays the icon next to a link to download the document. The ilUtil getTypeIconPath function is part of the ILIAS LMS, a learning management system that provides a wide range of tools for e-learning. It is included in the ilCommons library, which is a collection of utility classes used by various parts of the ILIAS system.