Location: PHPKode > projects > Gsys > php/directory_full_info.php
//Filename : directory_full_info.php
//Description :  Script to display a users full information
//Author :  darc
//Last modified :  2006.12.20

    include '../includes/auth.php';
    include '../includes/db.php';
	include '../includes/vars.php';

//if show_all was checked, show all brothers.
    if($_POST[show_all] == true)
    	$sql ="SELECT *  FROM $table_name ORDER BY l_name;";
    	$result = mysql_query($sql,$connection) or die(mysql_error());

else if($_POST[show_all] == false)

    	$sql ="SELECT pin_num, username, l_name, m_name, f_name, nickname, phone, address, town, state, zip, initiation_date, dob, email, on_off_campus, house, status, pos FROM $table_name where username='$_POST[more_info]';";
    	$result = mysql_query($sql,$connection) or die(mysql_error());

//set variables
        while($row =mysql_fetch_array($result))
    		$id = $row['pin_num'];
    		$f_name = $row['f_name'];
			$m_name = $row['m_name'];
    		$l_name = $row['l_name'];
			$nickname = $row['nickname'];
            $username = $row['username'];
            $phone = $row['phone'];
            $email = $row['email'];
            $address = $row['address'];
            $town = $row['town'];
            $state = $row['state'];
            $zip = $row['zip'];
            $initiation_date = $row['initiation_date'];
            $dob = $row['dob'];
            $on_off_campus = $row['on_off_campus'];
			$house = $row['house'];
			$status = $row['status'];
			$pos = $row['pos'];

//define page title
	$title = "$l_name, $f_name";

<?php include ('../includes/header.php');?>

		<div align="center">
        <h1><font size="5">Detailed Information For: <?php echo "$l_name, $f_name" ?></font></h1>
        <table width="71%" style="table">
            <td width="31%">Name: </td>
            <td width="69%"><?php echo "$l_name, $f_name $m_name" ?></td>
		  <?php if(!$nickname); else echo "<tr>
		  <td>"; echo "$nickname"; echo "</td>
            <td>Phone: </td>
            <td><?php echo "$phone" ?></td>
            <td>E-Mail: </td>
            <td><?php echo "$email" ?></td>
            <td>Address: </td>
            <td><?php echo "$address" ?><br> <?php echo "$town" ?>, <?php echo "$state" ?> 
              <?php echo "$zip" ?></td>
            <td>Initiation Date: </td>
            <td><?php echo "$initiation_date" ?></td>
            <td>Date of Birth: </td>
            <td><?php echo "$dob" ?></td>
		  <td>Current Status: </td>
		  <td><?php echo "$status" ?></td>
		  <?php if(!$pos); else echo "<tr>
		  <td>Current Position:</td>
		  <td>"; echo "$pos"; echo "</td>
            <td colspan="2">Currently residing <?php if ($house == "house")
													  	echo "in the house.";
													  	else echo "$on_off_campus", " campus.";
<?php include ('../includes/footer.php');?>
Return current item: Gsys