I have a Array like below:
Array
(
[0] => Select one
[1] => FB
[2] => RM
[3] => Joey
[4] => Isaac
[5] => Christina
[6] => James
[7] => Armando
[8] => Kent
[9] => Tyler
[10] => Michael
[11] => Dylan
[12] => Ryan
)
I want to convert it to 0:None;1:FB;2:RM;3:Joey;4:Isaac;5:Christina;6:James;7:Armando;8:Kent;9:Tyler;10:Michael;11:Dylan
I can do it using FOR loop and using IF, But I want to know the shortest way or is there any function available.
Any reference will be helpfull.
Thanks in advance.
serialize()doesnt work for you ?serializeis not working.array_map()withimplode(), And there are no such functions or methods that your 'Select One' changed to None, You need to useIF.