I want to find number of similar words between two texts
Example
$str1=the cat is on the roof
$str2=the mouse is on the roof
the,is,on,the,roof words are similar in $str1 and $str2
So output will be in number 5 OR In percentage 86%
I am try similar_text() function but this function not work as which i want.
similar_text
provides 83% as well, sure looks right to me