How can one check if the GD-Lib is installed in PHP?

To check if the GD-Lib is installed in PHP, you can use the `extension_loaded` function to determine if the GD extension is loaded. This function returns true if the specified extension is loaded, and false otherwise. By checking if the GD extension is loaded, you can ensure that the necessary functions for image manipulation are available in your PHP environment.

if (extension_loaded('gd')) {
    echo 'GD-Lib is installed';
} else {
    echo 'GD-Lib is not installed';
}