<?php
$cats = array(
(object) array("term_id"=>"","name"=>"Film : FIILMTOFTWFUT : post-COLON2","slug" => "alphabetical-k-l-m-n-o ","term_group"=>5,"term_taxonomy_id"=>9,"taxonomy"=>"Myanmar","description"=>"69509","parent"=>"","count"=>"1"),
(object) array("term_id"=>"","name"=> "Country: Cambodia ","slug"=>"Media Relations","term_group"=>5,"term_taxonomy_id"=>7,"taxonomy"=>"Belgium","description"=>"14234","parent"=>"","count"=>"1"),
(object) array("term_id"=>"","name"=>"Advertising","slug"=>"Quality Assurance","term_group"=>5,"term_taxonomy_id"=>1,"taxonomy"=>"Norfolk Island","description"=>"93236","parent"=>"","count"=>"1"),
(object) array("term_id"=>"","name"=>"Finances","slug"=>"Legal Department","term_group"=>5,"term_taxonomy_id"=>5,"taxonomy"=>"Honduras","description"=>"74759","parent"=>"","count"=>"1"),
(object) array("term_id"=>"","name"=>"Legal Department","slug"=>"Media Relations","term_group"=>1,"term_taxonomy_id"=>9,"taxonomy"=>"Namibia","description"=>"69625","parent"=>"","count"=>"1"),
(object) array("term_id"=>"","name"=>"Sales and Marketing","slug"=>"Advertising","term_group"=>2,"term_taxonomy_id"=>4,"taxonomy"=>"Syria","description"=>"56469","parent"=>"","count"=>"1"),
(object) array("term_id"=>"","name"=>"Finances","slug"=>"Media Relations","term_group"=>5,"term_taxonomy_id"=>8,"taxonomy"=>"Ethiopia","description"=>"74909","parent"=>"","count"=>"1"),
(object) array("term_id"=>"","name"=>"Media Relations","slug"=>"Asset Management","term_group"=>5,"term_taxonomy_id"=>9,"taxonomy"=>"Indonesia","description"=>"17623","parent"=>"","count"=>"1"),
(object) array("term_id"=>"","name"=>"Finances","slug"=>"Customer Relations","term_group"=>2,"term_taxonomy_id"=>3,"taxonomy"=>"Zimbabwe","description"=>"83249","parent"=>"","count"=>"1"),
(object) array("term_id"=>"","name"=>"Sales and Marketing","slug" => "alphabetical-k-l-m-n-o ","term_group"=>1,"term_taxonomy_id"=>10,"taxonomy"=>"Faroe Islands","description"=>"03778","parent"=>"","count"=>"1"),
(object) array("term_id"=>"","name"=>"Sales and Marketing","slug"=>"Sales and Marketing","term_group"=>7,"term_taxonomy_id"=>3,"taxonomy"=>"Latvia","description"=>"68525","parent"=>"","count"=>"1"),
(object) array("term_id"=>"","name"=>"Accounting","slug"=>"Research and Development","term_group"=>9,"term_taxonomy_id"=>7,"taxonomy"=>"Bouvet Island","description"=>"18959","parent"=>"","count"=>"1"),
(object) array("term_id"=>"","name"=>"Asset Management","slug"=>"Advertising","term_group"=>1,"term_taxonomy_id"=>9,"taxonomy"=>"Tajikistan","description"=>"94796","parent"=>"","count"=>"1"),
(object) array("term_id"=>"","name"=>"Tech Support : arstatf","slug"=>"Accounting","term_group"=>5,"term_taxonomy_id"=>7,"taxonomy"=>"Côte D'Ivoire (Ivory Coast)","description"=>"24209","parent"=>"","count"=>"1"),
(object) array("term_id"=>"","name"=>"Film : FIILMTOFTWFUT : post-COLON2","slug"=>"Human Resources","term_group"=>9,"term_taxonomy_id"=>3,"taxonomy"=>"Ukraine","description"=>"77647","parent"=>"","count"=>"1"),
(object) array("term_id"=>"","name"=>"Media Relations","slug"=>"Customer Service","term_group"=>6,"term_taxonomy_id"=>7,"taxonomy"=>"Maldives","description"=>"97264","parent"=>"","count"=>"1")
);
//list($k, $v) =
//print_r(explode(' ',$cat->name,2));
//$result[$k]=$v;
// $result[] = array_map(function($v){
// return explode(" ", $v);
// }, $cat);
function getStuff($o) {
$z= get_object_vars($o);
//return $z;
explode(' ',$o->name,2)//[0]//]= explode('',$o->name,2)[1];
;
}
$a=array_map('getStuff', $cats);
print_r($a)
?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename: /in/iMvgO
function name: (null)
number of ops: 42
compiled vars: !0 = $cats, !1 = $a
line #* E I O op fetch ext return operands
-------------------------------------------------------------------------------------
4 0 E > CAST 8 ~2 <array>
1 INIT_ARRAY ~3 ~2
5 2 CAST 8 ~4 <array>
3 ADD_ARRAY_ELEMENT ~3 ~4
6 4 CAST 8 ~5 <array>
5 ADD_ARRAY_ELEMENT ~3 ~5
7 6 CAST 8 ~6 <array>
7 ADD_ARRAY_ELEMENT ~3 ~6
8 8 CAST 8 ~7 <array>
9 ADD_ARRAY_ELEMENT ~3 ~7
9 10 CAST 8 ~8 <array>
11 ADD_ARRAY_ELEMENT ~3 ~8
10 12 CAST 8 ~9 <array>
13 ADD_ARRAY_ELEMENT ~3 ~9
11 14 CAST 8 ~10 <array>
15 ADD_ARRAY_ELEMENT ~3 ~10
12 16 CAST 8 ~11 <array>
17 ADD_ARRAY_ELEMENT ~3 ~11
13 18 CAST 8 ~12 <array>
19 ADD_ARRAY_ELEMENT ~3 ~12
14 20 CAST 8 ~13 <array>
21 ADD_ARRAY_ELEMENT ~3 ~13
15 22 CAST 8 ~14 <array>
23 ADD_ARRAY_ELEMENT ~3 ~14
16 24 CAST 8 ~15 <array>
25 ADD_ARRAY_ELEMENT ~3 ~15
17 26 CAST 8 ~16 <array>
27 ADD_ARRAY_ELEMENT ~3 ~16
18 28 CAST 8 ~17 <array>
29 ADD_ARRAY_ELEMENT ~3 ~17
19 30 CAST 8 ~18 <array>
31 ADD_ARRAY_ELEMENT ~3 ~18
2 32 ASSIGN !0, ~3
42 33 INIT_FCALL 'array_map'
34 SEND_VAL 'getStuff'
35 SEND_VAR !0
36 DO_ICALL $20
37 ASSIGN !1, $20
43 38 INIT_FCALL 'print_r'
39 SEND_VAR !1
40 DO_ICALL
46 41 > RETURN 1
Function getstuff:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename: /in/iMvgO
function name: getStuff
number of ops: 12
compiled vars: !0 = $o, !1 = $z
line #* E I O op fetch ext return operands
-------------------------------------------------------------------------------------
35 0 E > RECV !0
36 1 INIT_FCALL 'get_object_vars'
2 SEND_VAR !0
3 DO_ICALL $2
4 ASSIGN !1, $2
38 5 INIT_FCALL 'explode'
6 SEND_VAL '+'
7 FETCH_OBJ_R ~4 !0, 'name'
8 SEND_VAL ~4
9 SEND_VAL 2
10 DO_ICALL
40 11 > RETURN null
End of function getstuff
Generated using Vulcan Logic Dumper, using php 8.0.0
preferences:
186.46 ms | 1400 KiB | 21 Q