when i echo my array it's looks like this
[0] => Array
(
[carriertype] =>
[radiotype] => RRUS 12 B2
[serialnumber] => CF82943634
[market] => Detroit Westland - DET 5
[bts] => 225011
[Host] => 225011_21_MILE_and_ROMEO_PLANK
[resourceId] => 0
[type] => XMU
[port] => 16
[EP_AuxPlugInUnit_AuxPlugInUnitId] => RRU-7
[userlabletext] => 225011_1_4
[flag] => Yes
)
[1] => Array
(
[carriertype] =>
[radiotype] => RRUS 12 B2
[serialnumber] => CF82961338
[market] => Detroit Westland - DET 5
[bts] => 225011
[Host] => 225011_21_MILE_and_ROMEO_PLANK
[resourceId] => 0
[type] => XMU
[port] => 15
[EP_AuxPlugInUnit_AuxPlugInUnitId] => RRU-8
[userlabletext] => 225011_2_4
[flag] => Yes
)
[2] => Array
(
[carriertype] =>
[radiotype] => RRUS 12 B2
[serialnumber] => CF82943628
[market] => Detroit Westland - DET 5
[bts] => 225011
[Host] => 225011_21_MILE_and_ROMEO_PLANK
[resourceId] => 0
[type] => XMU
[port] => 14
[EP_AuxPlugInUnit_AuxPlugInUnitId] => RRU-9
[userlabletext] => 225011_3_4
[flag] => Yes
)
[3] => Array
(
[radiotype] =>
[carriertype] =>
[serialnumber] =>
[market] => Detroit Westland - DET 5
[bts] => 225011
[Host] => 225011_21_MILE_and_ROMEO_PLANK
[resourceId] => 0
[type] => XMU
[port] => 1
[EP_AuxPlugInUnit_AuxPlugInUnitId] =>
[userlabletext] => ___B
[flag] => Yes
)
[4] => Array
(
[radiotype] =>
[carriertype] =>
[serialnumber] =>
[market] => Detroit Westland - DET 5
[bts] => 225011
[Host] => 225011_21_MILE_and_ROMEO_PLANK
[resourceId] => 0
[type] => XMU
[port] => 1
[EP_AuxPlugInUnit_AuxPlugInUnitId] =>
[userlabletext] => ___E
[flag] => Yes
)
[5] => Array
(
[carriertype] => AWS
[radiotype] => RRUS 12 B4
[serialnumber] => CF81666912
[market] => Detroit Westland - DET 5
[bts] => 225011
[Host] => 225011_21_MILE_and_ROMEO_PLANK
[resourceId] => 0
[type] => XMU
[port] => 16
[EP_AuxPlugInUnit_AuxPlugInUnitId] => RRU-5
[userlabletext] => 225011_2_2
[flag] => Yes
)
[6] => Array
(
[carriertype] => AWS
[radiotype] => RRUS 12 B4
[serialnumber] => CF81666918
[market] => Detroit Westland - DET 5
[bts] => 225011
[Host] => 225011_21_MILE_and_ROMEO_PLANK
[resourceId] => 0
[type] => XMU
[port] => 14
[EP_AuxPlugInUnit_AuxPlugInUnitId] => RRU-6
[userlabletext] => 225011_3_2
[flag] => Yes
)
but i want array merge with same port value. in above array i have two 16,14 and 1 port nos. so they should merge with same value and if some value is differ then it should be save with comma between value. resulting array should like
[0] => Array
(
[carriertype] => AWS
[radiotype] => RRUS 12 B2,RRUS 12 B4
[serialnumber] => CF82943634,CF81666912
[market] => Detroit Westland - DET 5
[bts] => 225011
[Host] => 225011_21_MILE_and_ROMEO_PLANK
[resourceId] => 0
[type] => XMU
[port] => 16
[EP_AuxPlugInUnit_AuxPlugInUnitId] => RRU-7,RRU-5
[userlabletext] => 225011_1_4,225011_2_2
[flag] => Yes
)
[1] => Array
(
[carriertype] =>
[radiotype] => RRUS 12 B2
[serialnumber] => CF82961338
[market] => Detroit Westland - DET 5
[bts] => 225011
[Host] => 225011_21_MILE_and_ROMEO_PLANK
[resourceId] => 0
[type] => XMU
[port] => 15
[EP_AuxPlugInUnit_AuxPlugInUnitId] => RRU-8
[userlabletext] => 225011_2_4
[flag] => Yes
)
[2] => Array
(
[carriertype] => AWS
[radiotype] => RRUS 12 B2,RRUS 12 B4
[serialnumber] => CF82943628,CF81666918
[market] => Detroit Westland - DET 5
[bts] => 225011
[Host] => 225011_21_MILE_and_ROMEO_PLANK
[resourceId] => 0
[type] => XMU
[port] => 14
[EP_AuxPlugInUnit_AuxPlugInUnitId] => RRU-9,RRU-6
[userlabletext] => 225011_3_4,225011_3_2
[flag] => Yes
)
[3] => Array
(
[radiotype] =>
[carriertype] =>
[serialnumber] =>
[market] => Detroit Westland - DET 5
[bts] => 225011
[Host] => 225011_21_MILE_and_ROMEO_PLANK
[resourceId] => 0
[type] => XMU
[port] => 1
[EP_AuxPlugInUnit_AuxPlugInUnitId] =>
[userlabletext] => ___B,___E
[flag] => Yes
)
it should be done programmatic. please help me.