This is the PHP implementation of Simon White's string matching algorithm, available at http://www.catalysoft.com/articles/StrikeAMatch.html. This implementation is placed in the Public Domain: do whatever you want with it.
require_once('LetterPairSimilarity.class.php');
...
...
$similarity = LetterPairSimilarity::compareStrings('France', 'French Republic');
...