Created
September 4, 2012 16:38
-
-
Save Morrisai/3623246 to your computer and use it in GitHub Desktop.
displaying and formatting faculty names
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="profile_detail"> <span class="title04"> | |
<?php | |
$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 /> | |
<?php | |
echo $example; | |
?></span> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment