I don't understand why my really simple regex react like that, I've never been in this situation before:
$string = "you are the best pirate of the world";
if (preg_match_all("/pira|pirate|wor|world/", $string, $output)) {
// $output => array(array('pira', 'wor'));
}
http://www.phpliveregex.com/p/meS : on this link you will have a bette view. So here, the output is "pira" and "wor" whereas I want to have "pirate" and "world". I must have missed something.
How to make it match the exact word ?