public static function _getPS2Activity($char)
 {
     $census = new Census();
     $character = $census->getUserByName($char);
     if (!empty($character)) {
         $character->playtime = $census->playtime($character->character_id);
         $character->squadleading = $census->squadleading($character->character_id);
         $character->platoonleading = $census->platoonleading($character->character_id);
         Flight::json($character);
     } else {
         $error = new stdClass();
         $error->error = "Character Not Found";
         Flight::json($error);
     }
 }
<?
require_once( "../../models/Census.php" );
require_once( "../../models/Patient.php" );

$census = new Census( 'MSU' );
$census->populateCensus( Connection::getInstance() );
$patients = $census->getPatients();
/*********************************************8
$dom = new DOMDocument("1.0");
$xml = $dom->createElement( "module" );
$dom->appendChild( $xml );
$name = $dom->createAttribute( "name" );
$value = $dom->createTextNode( "PatientModuleList" );
$name->appendChild( $value );
$xml->appendChild( $name );

$patientNode = null;
$firstName = null;
$lastName = null;
$value = null;

foreach( $patients as $patient ) {
	$patientNode = $dom->createElement( "patient" );

	$firstName = $dom->createElement( "firstName" );
	$value = $dom->createTextNode( $patient->getFirstName() . " " );
	$firstName->appendChild( $value );

	$lastName = $dom->createElement( "lastName" );
	$value = $dom->createTextNode( $patient->getLastName() );
	$lastName->appendChild( $value );