Administrators Thanked: 265 times
Если нужно просто посчитать вложенность:
$nesting_count
= substr_count(
$structure
[
'page'
][
$c
'path'
]),
'.'
);