Core Function Metaphone

From Sputnik Wiki
Revision as of 09:01, 20 September 2013 by UberFoX (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
Metaphone( <string>, <phonemes> )

Contents

Description

Calculate the metaphone key of a string.

Parameters

string

The input string.

phonemes

Optional; This parameter restricts the returned metaphone key to phonemes characters in length.

The default value of 0 means no restriction.

Return Value

Success: Returns the metaphone key as a string.

Failure: Returns empty string.

Remarks

None.

Example

echo Metaphone("programming"); // PRKRMNK
echo("\n");
echo Metaphone("programmer"); // PRKRMR
 
echo("\n");
 
echo metaphone('programming', 5); // PRKRM
echo("\n");
echo metaphone('programmer', 5); // PRKRM
Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox