Compare Two String Similar Script

Compare Two String Similar Script is used to test if the strings sound alike.

Demo :



Type Text 1 Type Text 2  

Example :

Example 1:  rest    reset

Example 2:  deep    dip

Example 3:  fire    higher

If you need to compare similar sound text code you copy following code and use to your website.

<?php
echo (metaphone('fire') == metaphone('higher')) ? "Strings are similar" : "Strings are not similar";
?>

In the above code is used to compare same sound text. if string sound is similar "Strings are similar" output message will display otherwise "Strings are not similar" message will display.

The basic english pronunciation function is called metaphone () function. There are two parameter used to metaphone function . The first one is string text parameter and second one is int phones parameter.

<form id="compare_string" name="compare_string" method="post">
  <input type="text" id="text_1" name="text_1" >
  <input type="text" id="text_2" name="text_2">
  <input type="submit" value="Check"/>
</form>

In the above form is used to Compare Two String Similar Script.when click in the Check button form will pass the string through POST method.

Free Download Script :

If you need Compare Two String Similar Script click and download from following link.

Download




Content