I have an indexed array as follows
$item = array("one", "two", "three", "four");
I need to change the index of this array with another array
$indexarray = array("2", "0", "3", "1");
assign new index to $item array like this,
one ---> 2
two ---> 0
three ---> 3
four ---> 1
Required result:
$item = array("two", "four", "one", "three");
array("2","0","3","1");orarray(2,0,3,1);?