Comparing strings : String « String « PHP
- PHP
- String
- String
Comparing strings
<?
$word = 'baa';
if ($word < 'baa') {
print "Your word probably starts with 'A'.";
}
if ($word >= 'zoo') {
print "Your word could be zoo or zymurgy, but not zone.";
}
?>
Related examples in the same category