$url = 'https://example.com'; if (GeneralUtility::isValidUrl($url)) { echo 'Valid URL'; } else { echo 'Invalid URL'; }In this example, we are passing a URL to the isValidUrl() function and checking if it returns true or false. If it returns true, then the URL is considered valid and the message "Valid URL" is displayed. If it returns false, then the message "Invalid URL" is displayed. This function is part of the TYPO3 CMS core utility library, which is included with the CMS package.