0
I would like to check that all values in my array are equal and I did so :
$minha_lista = array('a','a','a');
if(!empty($minha_lista)) {
if(count(array_unique($minha_lista))===1){
return true;
} else { return false; }
}
Unfortunately I can’t get the desired result.
There is another way to proceed ?
But apparently if code is right, what’s wrong or what he doesn’t do?
– novic
your code is correct, you don’t need anything! only if you have something you’re not reporting in your question ... !!!
– novic
@André-pka Is there any other problem that is occurring? Because as the friend above said... Your code is correct.
– Cesar Augusto