Search
 
SCRIPT & CODE EXAMPLE
 

PHP

php add to multidimensional array

$array1 = array("color" => "red", 2, 4);
$array2 = array("a", "b", "color" => "green", "shape" => "trapezoid", 4);
$result = array_merge($array1, $array2);
print_r($result);
Comment

PREVIOUS NEXT
Code Example
Php :: thousand seperator php 
Php :: redirect back laravel 
Php :: laravel pagination vuetify 
Php :: laravel target is not instantiable while building 
Php :: Laravel Framework upgrade from older version 7.x to 8.x 
Php :: wordpress theme development boilerplate 
Php :: php convert guzzle response to json 
Php :: get post by meta value 
Php :: get file extension php 
Php :: array intersect 
Php :: wordpress get plugin root directory 
Php :: laravel get current route url 
Php :: string match percentage php 
Php :: php error log 
Php :: Array and string offset access syntax with curly braces is deprecated 
Php :: How to create and access angular HTTP params in PHP 
Php :: php var_dump more readable 
Php :: php - How do I calculate the percentage of a number? 
Php :: how to maintain serial number in pagination in laravel blade 
Php :: why session is not working in laravel 
Php :: convert array into , separated string in php 
Php :: merge collections laravel 
Php :: array php 
Php :: generate random string in php 
Php :: merge two objects php laravel 
Php :: php check if int is odd 
Php :: php artisan make :migration with model 
Php :: acf create post with fields 
Php :: destroy multiple sessions in laravel 
Php :: Remove revisions from Wordpress pages 
ADD CONTENT
Topic
Content
Source link
Name
1+9 =