$modules = getModulesInstalled(); print_r($modules);
if (in_array('gd', getModulesInstalled())) { // GD library is installed // Add code to manipulate images } else { // GD library is not installed // Add code to handle the absence of the library }In this example, the in_array function is used to check if the GD library is installed. If it is, code to manipulate images can be added. If it is not, code to handle the absence of the library can be added. The getModulesInstalled function is part of the PHP library, and it does not appear to be associated with any additional package library.