I have string from mysql in this format
1.name.2.name,3.name.8.name
I have this
$arr=split(“,”,$str);$count=count($arr);
this will make 2 arrays, but I want to write it itemized
for ($i=0;$i<$count;$i++){
echo $arr[$i];
// when $i=0 here must be 1 name 2 name and when $i=1 3 name 8 name
}
this is still right, but now I want inside loop write values from $arr[$i], I need to split them by dott. Is it possible?
You don’t need any loop
Output
If you want to break it further
Output