oracle259 Posted September 28, 2006 Share Posted September 28, 2006 apart from the built in similar_text() function how do i go about testing the similarity between two words. Link to comment https://forums.phpfreaks.com/topic/22330-text-similarity/ Share on other sites More sharing options...
BillyBoB Posted September 28, 2006 Share Posted September 28, 2006 *NOTE: ~ means simulari dont think i get the exact thing here do u want to know if they are ~ or do u want to define the difference?if u want to see if they are ~ then just do like[code]<?phpIf($var1==$var2) { echo("They are the same.");}else{ echo("They aren't the same.");}?>[/code] Link to comment https://forums.phpfreaks.com/topic/22330-text-similarity/#findComment-100037 Share on other sites More sharing options...
oracle259 Posted September 28, 2006 Author Share Posted September 28, 2006 Not really...in php you can use the following code:[code]$match = similar_text($compare1, $compare2, $percent);$percent = round($percent, 0);echo $pecent;[/code]to get the percentage similarity between ass and assets. But the percent comes to 0 which is not accurate i want to know if there is a better way to achieve a more accurate figure. Link to comment https://forums.phpfreaks.com/topic/22330-text-similarity/#findComment-100041 Share on other sites More sharing options...
BillyBoB Posted September 28, 2006 Share Posted September 28, 2006 ok sorry i cant help u there i dont know Link to comment https://forums.phpfreaks.com/topic/22330-text-similarity/#findComment-100044 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.