- reset: documentation ( source)
- end: documentation ( source)
- explode: documentation ( source)
<?php
$author = 'Jan Stanisław Nowak';
$foo = explode(' ', $author);
$firstName = reset($foo);
$lastName = end($foo);
echo $firstName . ' ' . $lastName;