PHP Programs

Please click on 1-2 Ads to keep this website's Study Material FREE and regularly Updated.

Program 6: Write a PHP function that checks if a string is all lower case.

lowercase.php

<!DOCTYPE html>
<html>
<head>
	<title>PHP Programs TutorialsDuniya.com</title>
</head>
<body>
	<?php
		$strings = array('HELLO', 'HOW', 'are', 'you');
		foreach($strings as $v) 
		{
			if (ctype_lower($v))
			{
				echo"The string $v consists of all lowercase letters.<br/>";
			}
			else
			{
				echo"The string $v does not consists of all lowercase letters.<br/>";
			}
		}
	?>
</body>
</html>



If you have any suggestion or found any error in the above program, then do let us know at [email protected] or just comment below.