0

I have 4 arrays for input errors like:

$username_errors=array();
$email_errors=array();
$password_errors=array();
$errors=array();

I want to merge all the arrays values in $errors array and count if $errors is empty then proceed. Thanks in advance.

3

2 Answers 2

1

use array_merge

$arr = array_merge($arr1, $arr2, $arr3);
Sign up to request clarification or add additional context in comments.

Comments

0
$array3 = array_merge($array1, $array2);

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.