I have two arrays
$array1 = array(33=>'abc,bcd,cde,def');
$array2 = array(33=>'fgh,ghi,hij,ijk');
How I can add two arrays to get the below result?
$array3 = array(33=>'abc,bcd,cde,def,fgh,ghi,hij,ijk');
Thanks in advance…
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
I presume you want to do this automatically for multiple keys. Try something like this:
Keep in mind you will need checks to see if the data is in both arrays if they do not exactly match.