Ахаха..
Коряво, но ладно.
echo clear_text('dFsdfjHdsfjJLdasNR');
function clear_text($text_1){
error_reporting(0);
$count_del = 0;
$text = preg_split('//', $text_1, -1, PREG_SPLIT_NO_EMPTY);
$texts = preg_split('//', $text_1, -1, PREG_SPLIT_NO_EMPTY);
for ($i=0; $i < count($text); $i++) {
if($count_del >= 0){
if(ctype_upper($texts[$i])){
if($texts[$i] == "F"){ $count_del++; unset($texts[$i]);}}}
if($count_del == 1 and ctype_upper($texts[$i])){
if($texts[$i] == "H"){ $count_del++; unset($texts[$i]);}}
if($count_del == 2 and ctype_upper($texts[$i])){
if($texts[$i] == "J"){ $count_del++; unset($texts[$i]);}}
if($count_del == 3 and ctype_upper($texts[$i])){
if($texts[$i] == "L"){ $count_del++; unset($texts[$i]);}}
if($count_del == 4 and ctype_upper($texts[$i])){
if($texts[$i] == "N"){ $count_del++; unset($texts[$i]);}}
if($count_del == 5 and ctype_upper($texts[$i])){
if($texts[$i] == "R"){ $count_del++; unset($texts[$i]);}}
}
$text2 = "";
foreach ($texts as $key) {
$text2 .= $key;
}
return $text2;
}