Skip to content
Create a gist now

Instantly share code, notes, and snippets.

displaying and formatting faculty names
<div class="profile_detail"> <span class="title04">
$firstpart = strtok($faculty_data['Faculty']['firstName']." ".$faculty['Faculty']['middleName']." ".$faculty_data['Faculty']['lastName']," ");
echo $firstpart;
$tot_len = strlen($faculty_data['Faculty']['firstName']." ".$faculty['Faculty']['middleName']." ".$faculty_data['Faculty']['lastName']);
$len = strlen($firstpart);
$example = substr($faculty_data['Faculty']['firstName']." ".$faculty['Faculty']['middleName']." ".$faculty_data['Faculty']['lastName'],$len,$tot_len-$len);
<br />
echo $example;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.