PHP numeric array order
问题 I have an array and want to create a new numeric array. This looks like this: $created_old = explode("_", $result[$i]["created"]); $created_new = array(); $created_new[0] = $created_old[2]; $created_new[1] = $created_old[0]; $created_new[2] = $created_old[1]; $created_new[3] = ""; $created_new[4] = rtrim(explode(":", $created_old[3])[2], ")"); //Get name from the database $created_new[3] = $name; $created = implode("_", $created_new); This version works just fine, but the previous was missing