I have an array that already contains all it\'s values in alphabetical order:
Alligator
Alpha
Bear
Bees
Banana
Cat
Cougar
Now I just want to li
Well i have three solutions. 1) Make another array containing all alphabets. Then use foreach to iterate through this array. And in nested foreach check for occurance of that letter through strpos method of php. Here is rough code.
2) second method have same logic as above. But here you dont need to make array for alphabets. You can get all alphabets this way.
Php range method
3) Third solution also have same logic as above two. Here you can get alphabets by another way :)
for ($i=65; $i< =90; $i++) {
$x = chr($i);
print $x;
}