3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = array( [ "product_id" => "1138", "product_image" => "/resources/medias/shop/products/shop-6500720--1.png", "product_sku" => "6500722" ], [ "product_id" => "1144", "product_image" => "/resources/medias/shop/products/shop-6501041--1.png", "product_sku" => "6501046" ], [ "product_id" => "113", "product_image" => "/resources/medias/shop/products/shop-6294909--1.png", "product_sku" => "6294915" ] ); $new = array_column($array, "product_id", "product_sku"); Var_dump($new);

preferences:
24.31 ms | 405 KiB | 5 Q