PHP Classes

PHP Parse Full Name: Parse person name and extract its components

Recommend this page to a friend!
     
  Info   Example   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not enough user ratingsTotal: 152 All time: 9,064 This week: 50Up
Version License PHP version Categories
fullnameparse 2Freely Distributable3.0PHP 5, User Management, Parsers
Description 

Author

This class can parse person name and extract its components.

It can take the full name of a person and extract its components like first name, middle name, last name, salutation and suffix.

The parsed name is returned as an associative array with entries for each found component.

Picture of Anthony Amolochitis
  Performance   Level  
Name: Anthony Amolochitis <contact>
Classes: 10 packages by
Country: United States United States
Age: 44
All time rank: 1138166 in United States United States
Week rank: 197 Up20 in United States United States Up

Example

require 'ParseName.php';

$_REQUEST['fullname'] = urlencode( 'Janet Louise Miller-Cross Jr' ) ;
$FullNameParse = new FullNameParse( urldecode( $_REQUEST['fullname'] ) );
$ParsedNameArray = $FullNameParse->GetParsedName();

echo json_encode( $ParsedNameArray ) ;

echo '<br/>';

$FullNameParse->SetFullName('Mr. Anthony John Amolochitis Senior');
$ParsedNameArray = $FullNameParse->GetParsedName();

echo json_encode( $ParsedNameArray ) ;


  Files folder image Files (2)  
File Role Description
Plain text file Example.php Example Example file
Plain text file ParseName.php Class Parse Full Names

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 0%
Total:152
This week:0
All time:9,064
This week:50Up