Closed. This question needs details or clarity. It is not currently accepting answers. Want to improve this question? Add details and clarify the problem by editing this post. Closed 2 years ago. This post was edited and submitted for review 20 days ago and failed to reopen the post: Original close reason(s) were not resolved Improve this question I’m trying
Tag: arrays
Access JSON Array Data Within Object With PHP
stdClass Object ( [id] => 8586332 [email] => hello@myemail.com [optInType] => Unknown [emailType] => Html [dataFields] => Array ( [0] => stdClass Object ( [key] => …
comparing 2 arrays for matching postal codes and grabbing the adjacent array value
I am trying to make a little batch upload tool to upload tracking numbers. I have a csv with 2 columns: postal_code, tracking_number and I have my sql that selects order_id, postal_code: //import …
Modify array during multiple foreach loop iterations
I’ve to update data for array which has 4 foreach loops, foreach ($dta[‘hotels’][‘hotels’] as $key => &$value) { foreach ($value[‘rooms’] as $key1 => $value1) { foreach …
update 2 dimensional array PHP
I made a 2 dimensional array which checks if 3 of the same values are equal to each other. My problem is that when the code detects 3 in a row it changes values, but it doesn’t update to the original array ($aww_ar). Is there a way to do this? Code: Answer Ive worked it out a bit with the
How to check a php array, that contain the same value as other array
i have two array which is $a and $b, where the value of the array is same but the index of elements is different. $a Array ( [0] => there is bald spot on the inside or outside of tyre [1] => …
How to store a zero in an array in php
I am trying to store the value 0 in an associative array to later use it as a key to another array. However I am not able to retrieve 0 with the code below. What happens is that in the while loop …
Concatenate values according to the same key value
Im some new in PHP and I want to join values according to drug key with the same id. My array: Array ( [0] => Array ( [id] => 17 [drug] => Clobazam …
How to get sum of array values according to some index (non-sorted)
I want the sum of monthly_rental and arc if the month and full_name are the same in one array. Input Array Array ( [0] => Array ( [0] => Array ( …
How to Get Data from this PHP Array? [closed]
Array ( [type] => 101 [width] => 540 [height] => 960 [url] => https://a.com) Array ( [type] => 102 [width] => 340 [height] => 604 [url] => https://b.com) Array ( [type] =>…