<?php $names = array("Tom Hanks", "Julia Roberts"); echo implode('/', preg_replace( "/([A-Z])\w+\h+(\w{4})\w*/", "$1$2", $names ) );
You have javascript disabled. You will not be able to edit any code.