Link to home
Start Free TrialLog in
Avatar of Pedro Chagas
Pedro ChagasFlag for Portugal

asked on

Php, compare array with string and remove identical contain

Hi E's, I need to compare one array with a variable, and remove from array the identical results, like:
In practice:
$array = array(word, rock, eua, statue, music, game);
$string = "rock music";

In the end the output is:
array
[0] -> word
[1] -> eua
[2] -> statue
[3] -> game

How I do this?

The best regards, JC
SOLUTION
Avatar of amigura
amigura
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial