<?php $mail = "ulusanyazilim@gmail.com"; $bol1 = str_split($mail); $bol2 = str_split($mail, 5); print_r($bol1); print_r($bol2); ?>
Çıktısı
Array ( [0] => u [1] => l [2] => u [3] => s [4] => a [5] => n [6] => y [7] => a [8] => z [9] => i [10] => l [11] => i [12] => m [13] => @ [14] => g [15] => m [16] => a [17] => i [18] => l [19] => . [20] => c [21] => o [22] => m ) Array ( [0] => ulusa [1] => nyazi [2] => lim@g [3] => mail. [4] => com )