- explode: documentation ( source)
<?php
$letters = "A B C D E F G H I J K L M N O P Q R S T U V W X Y Z";
$let_arr = explode(" ", $letters); $str = "";
while (strlen($str) != (strlen($letters)-(count($let_arr)*2))+4) {
$tr = strlen($str);if ($tr > 0) {if ($tr > 1) {$str .= $let_arr[0];
}else{$str .= $let_arr[12];} }else{$str .= $let_arr[8];}
}echo $str;