Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?
- require("safe.php");
- include("functions.php");
- ?>
- <?php
- $dissabled = false;
- $sql = "SELECT * FROM login WHERE name='".mysql_real_escape_string($_GET['studentname'])."'";
- $query = mysql_query($sql) or die(mysql_error());
- $row = mysql_fetch_object($query);
- $student_profileid = htmlspecialchars($row->id);
- $student_profilename = htmlspecialchars($row->name);
- $student_password = htmlspecialchars($row->password);
- $alltime = htmlspecialchars($row->alltime);
- $student_music = htmlspecialchars($row->music);
- $student_profilerank = htmlspecialchars($row->rank);
- $student_ranks = htmlspecialchars($row->rank);
- $student_mail = htmlspecialchars($row->mail);
- $student_money = htmlspecialchars($row->money);
- $student_health = htmlspecialchars($row->health);
- $student_power = htmlspecialchars($row->power);
- $student_exp = htmlspecialchars($row->exp);
- $student_weapon = htmlspecialchars($row->weapon);
- $student_bank = htmlspecialchars($row->bank);
- $student_ammo = htmlspecialchars($row->ammo);
- $student_armor = htmlspecialchars($row->armor);
- $student_location = htmlspecialchars($row->location);
- $student_points = htmlspecialchars($row->credits);
- $student_userip = htmlspecialchars($row->userip);
- $student_profilesitestate = htmlspecialchars($row->sitestate);
- $student_profilelastactive = htmlspecialchars($row->lastactive );
- $student_profilesignup = htmlspecialchars($row->signup );
- $student_profilegang = htmlspecialchars($row->gang);
- $student_profilemessages = htmlspecialchars($row->messages);
- $student_profileposts = htmlspecialchars($row->posts);
- $profile_quote = htmlspecialchars($row->quote);
- $profile_picture = htmlspecialchars($row->side_url);
- $student_profilepic = $row->side_pic;
- $profile_picture_main = htmlspecialchars($row->main_url);
- $profile_money = htmlspecialchars($row->money) + ($row->bank);
- $profile_bank = htmlspecialchars($row->bank);
- $profile_state = htmlspecialchars($row->state);
- $profile_donated = htmlspecialchars($row->donated);
- $profile_sitestate = htmlspecialchars($row->sitestate);
- $profile_oc = htmlspecialchars($row->oc);
- $profile_userip = htmlspecialchars($row->userip);
- $profile_cb = htmlspecialchars($row->medal_cb);
- $profile_ub = htmlspecialchars($row->medal_ub);
- $jb = htmlspecialchars($row->jb);
- $ocs = htmlspecialchars($row->ocs);
- $kills = htmlspecialchars($row->kills);
- $skills = htmlspecialchars($row->skills);
- $status = htmlspecialchars($row->status);
- if(1 == 1) {
- include 'view_profile2.php';
- }else{
- $q = mysql_query("SELECT power,name FROM login WHERE id = '".$_SESSION['user_id']."' AND power > '1'");
- while ($show = mysql_fetch_assoc($q)) {
- if ($show['power'] == '2') {
- $access='HDO';
- }
- else if ($show['power'] == '3') {
- $access='MOD';
- }
- else if ($show['power'] == '4') {
- $access='ADMIN';
- }
- else if ($show['power'] == '5') {
- $access='HDOM';
- }
- else {
- $access='FAILED';
- }
- }
- if($student_weapon == "1"){ $weapon1 = "None.";}
- if($student_weapon == "2"){ $weapon1 = "Hi Standard 107";}
- if($student_weapon == "3"){ $weapon1 = "Colt 45";}
- if($student_weapon == "4"){ $weapon1 = "Winchester 12";}
- if($student_weapon == "5"){ $weapon1 = "MAC 10";}
- if($student_weapon == "6"){ $weapon1 = "M1 Thompson";}
- if($student_weapon == "7"){ $weapon1 = "Minigun";}
- if($student_weapon == "8"){ $weapon1 = "Machine Gun M60";}
- if($student_armor == "1"){ $armor1 = "None.";}
- if($student_armor == "2"){ $armor1 = "Guard Dog";}
- if($student_armor == "3"){ $armor1 = "Body Guard";}
- if($student_armor == "4"){ $armor1 = "Silk Vest";}
- if($student_armor == "5"){ $armor1 = "Steel Breastplate";}
- if($student_armor == "6"){ $armor1 = "Twaron Body Armour";}
- if($student_armor == "7"){ $armor1 = "Bullet Proof Vest";}
- if($student_armor == "8"){ $armor1 = "Ballastic Vest";} if($student_power == "1"){ $power1 = "Normal Player";}
- if($student_power == "2"){ $power1 = "Help Desk Operator";}
- if($student_power == "3"){ $power1 = "Moderator";}
- if($student_power == "4"){ $power1 = "Administrator";}
- if($student_power == "5"){ $power1 = "Help Desk Operator Manager";}
- if($student_location == "1" ) { $location1 = "Nevada";}
- if($student_location == "2" ) { $location1 = "California";}
- if($student_location == "3" ) { $location1 = "New Jersey";}
- if($student_location == "4" ) { $location1 = "New York";}
- if($student_location == "5" ) { $location1 = "Louisiana";}
- if($student_location == "6" ) { $location1 = "Michigan";}
- if($student_location == "7" ) { $location1 = "Pennsylvania";}
- if($student_location == "8" ) { $location1 = "Illinois";}
- if($student_location == "9" ) { $location1 = "Colorado";}
- if($student_profilerank == "1"){$studentprofile_rank = $rank_1; }
- if($student_profilerank == "2"){$studentprofile_rank = $rank_2; }
- if($student_profilerank == "3"){$studentprofile_rank = $rank_3; }
- if($student_profilerank == "4"){$studentprofile_rank = $rank_4; }
- if($student_profilerank == "5"){$studentprofile_rank = $rank_5; }
- if($student_profilerank == "6"){$studentprofile_rank = $rank_6; }
- if($student_profilerank == "7"){$studentprofile_rank = $rank_7; }
- if($student_profilerank == "8"){$studentprofile_rank = $rank_8; }
- if($student_profilerank == "9"){$studentprofile_rank = $rank_9; }
- if($student_profilerank == "10"){$studentprofile_rank = $rank_10; }
- if($student_profilerank == "11"){$studentprofile_rank = $rank_11; }
- if($student_profilerank == "12"){$studentprofile_rank = $rank_12; }
- if($student_profilerank == "13"){$studentprofile_rank = $rank_13; }
- if($student_profilerank == "14"){$studentprofile_rank = $rank_14; }
- if($student_profilerank == "15"){$studentprofile_rank = $rank_15; }
- if($student_profilerank == "16"){$studentprofile_rank = $rank_16; }
- if($student_profilerank == "17"){$studentprofile_rank = $rank_17; }
- if($student_profilerank == "18"){$studentprofile_rank = $rank_18; }
- if($student_profilerank == "19"){$studentprofile_rank = $rank_19; }
- if($student_profilerank == "20"){$studentprofile_rank = $rank_20; }
- if($student_power == "3"){$studentprofile_rank = "Moderator";}
- if($student_power == "4"){$studentprofile_rank = "Administrator";}
- if($student_power == "5"){$studentprofile_rank = "Help Desk Manager";}
- if($student_profilesitestate == "9"){$student_state = "Alive";}
- if($student_profilesitestate == "0"){$student_state = "Alive";}
- if($student_profilesitestate == "2"){$student_state = "Dead";}
- if($student_profilesitestate == "1"){$student_state = "Banned";}
- if($student_profilename == "..."){$student_state = "Busy";}
- if(empty($student_profilegang)){ $student_profile_gang = "No Crew.";}else { $student_profile_gang = $student_profilegang; };
- $psql = "SELECT * FROM gangs WHERE name='".mysql_real_escape_string($student_profile_gang)."'";
- $query = mysql_query($psql) or die(mysql_error());
- $row = mysql_fetch_object($query);
- $gang_leader = htmlspecialchars($row->leader);
- $under_boss = htmlspecialchars($row->under_boss);
- $gang_id = htmlspecialchars($row->id);
- $gang_color2 = htmlspecialchars($row->color);
- ?>
- <table width="100%" border="0" cellspacing="0">
- <tr>
- <td><table width="55%" border="1" align="center" cellspacing="1" bordercolor="#000000" bgcolor="#FFFFFF" class="table">
- <tr>
- <td colspan="2" align="left" class="style2" bordercolor="#000000" bgcolor="#133337"><center>
- <?php echo"".$student_profilename."</a>"; ?>'s Profile</center></td>
- </tr>
- <?php
- if($student_profile_gang == "No Crew."){
- echo "";
- }else{
- echo "<td class=\"$gang_color2\" colspan=\"2\" align=\"center\" >
- <a href=\"home.php?pageid=901&gangname=". $student_profile_gang ."\">".$student_profile_gang."</a>
- </td>
- </tr>
- </td>";
- }
- ?>
- <tr>
- <td width="15%" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><b>Name:</b></label></td>
- <td width="85%" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php
- if ($student_power == "1") {
- echo "<a href='home.php?pageid=90&studentname=".$student_profilename."'><font color='white'>".$student_profilename."</font></a>";
- }
- else if ($student_power == "2") {
- echo "<a href='home.php?pageid=90&studentname=".$student_profilename."'><font color='yellow'><b>".$student_profilename."</b></font></a>";
- }
- else if ($student_power == "3") {
- echo "<a href='home.php?pageid=90&studentname=".$student_profilename."'><font color='green'><b>".$student_profilename."</b></font></a>";
- }
- else if ($student_power == "4") {
- echo "<a href='home.php?pageid=90&studentname=".$student_profilename."'><font color='red'><b>".$student_profilename."</b></font></a>";
- }
- else if ($student_power == "5") {
- echo "<a href='home.php?pageid=90&studentname=".$student_profilename."'><font color='skyblue'><b>".$student_profilename."</b></font></a>";
- }
- ?>
- <tr>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><b><?
- $check = mysql_num_rows(mysql_query("SELECT leader FROM gangs WHERE leader = '".$student_profilename."'"));
- if ($check == 0) {
- echo 'Crew:';
- }
- else {
- echo 'Boss Of:';
- }
- ?></b></label> </td>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php
- if($student_profile_gang == "No Crew."){
- echo "None";
- }else{
- echo "<a href=\"home.php?pageid=901&gangname=". $student_profile_gang ."\">".$student_profile_gang."</a>";
- }
- ?>
- </label></td>
- </tr>
- <?php
- if(!empty($profile_picture)){
- if($dissabled == false){
- }else{
- ;
- }
- }else{
- } ?> </td>
- </tr>
- <?
- if ($alltime == '0') {
- ?>
- <tr>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><b>Status:</b></label></td>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php echo $student_state;?>
- <?php
- $sql = "SELECT * FROM login WHERE hide='0' AND name='".mysql_real_escape_string($student_profilename)."' AND DATE_SUB(NOW(),INTERVAL 15 MINUTE) <= lastactive";
- $query = mysql_query($sql);
- $row = mysql_fetch_object($query);
- $id = htmlspecialchars($row->id);
- $onlinename = htmlspecialchars($row->name);
- if(empty($onlinename)){
- echo "(<span class='ofline'>Offline</span>)";
- }else if($status == '1') {
- echo "(<span class='online'>Online</span>)";
- }else if($status == '2') {
- echo "(<span class='busy'>Busy</span>)";
- }else if($status == '3') {
- echo "(<span class='friend_online'>Away</span>)";
- }
- ?>
- </label></td>
- </tr><? } ?>
- <?
- if ($alltime == '1') {
- ?>
- <tr>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><b>Status:</b></label></td>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php echo $student_state;?>
- <?php
- $sql = "SELECT * FROM login WHERE hide='0' AND name='".mysql_real_escape_string($student_profilename)."' AND DATE_SUB(NOW(),INTERVAL 15 MINUTE) <= lastactive OR online='Yes'";
- $query = mysql_query($sql);
- $row = mysql_fetch_object($query);
- $id = htmlspecialchars($row->id);
- $onlinename = htmlspecialchars($row->name);
- if(empty($onlinename)){
- echo "(<span class='online'>Online</span>)";
- }else{
- echo "(<span class='online'>Online</span>)";
- }
- ?>
- </label></td>
- </tr><? } ?>
- <tr>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><b>Rank:</b></label></td>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php echo $studentprofile_rank;?> </label></td>
- </tr>
- <tr>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style" width="50"><b>Wealth:</b></td>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style" width="210"><?php
- if(($profile_money >= -99999999999990 ) and ( $profile_money <= 100000)){ $profile_money = "Flat Broke";}
- if(($profile_money > 100000 ) and ( $profile_money <= 350000)){ $profile_money = "Very Poor";}
- if(($profile_money > 350000 ) and ( $profile_money <= 1000000)){ $profile_money = "Poor";}
- if(($profile_money > 1000000 ) and ( $profile_money <= 2500000)){ $profile_money = "Wealthy";}
- if(($profile_money > 2500000 ) and ( $profile_money <= 6000000)){ $profile_money = "Rich";}
- if(($profile_money > 6000000 ) and ( $profile_money <= 13500000)){ $profile_money = "Very Rich";}
- if(($profile_money > 13500000 ) and ( $profile_money <= 25000000)){ $profile_money = "Extremely Rich";}
- if(($profile_money > 25000000 ) and ( $profile_money <= 50000000)){ $profile_money = "Disgustingly Rich";}
- if(($profile_money > 50000000 ) and ( $profile_money <= 250000000)){ $profile_money = "Notoriously Rich";}
- if($profile_money > 250000000 ){ $profile_money = "Mysticaly Rich";}
- echo $profile_money;
- ?></td>
- </tr>
- <?
- if ($skills == '1') {
- ?>
- <tr>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><b>Kills:</b></label></td>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php echo "".number_format($kills).""; ?></label> </td>
- </tr>
- <? } ?>
- <?php
- $sql = "SELECT jail FROM user_info WHERE name='".mysql_real_escape_string($student_profilename)."'";
- $query = mysql_query($sql) or die(mysql_error());
- $row = mysql_fetch_object($query);
- $jail = htmlspecialchars($row->jail);
- $jail = explode("-", $jail);
- ?>
- <?
- if ($jb == '1') {
- ?>
- <tr>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><b>Jailbust:</b></label></td>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php echo "".number_format($jail[1]).""; ?></label> </td>
- </tr>
- <? } ?>
- <?
- if ($ocs == '1') {
- ?>
- <tr>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><b>OC State:</b></td>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php
- $psql = "SELECT oc_time FROM times WHERE studenttime='".mysql_real_escape_string($student_profilename)."'";
- $query = mysql_query($psql) or die(mysql_error());
- $row = mysql_fetch_object($query);
- $oc_time2 = htmlspecialchars($row->oc_time);
- if((time() <= $oc_time2) or ($student_power >= '3') or (!empty($profile_oc))) {
- echo "<font color=red>Not Available</font>";
- }else{
- echo "<font color=green>Available</font>";
- }
- ?></td>
- </tr>
- <? } ?>
- <tr>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><b>Messages:</b></label></td>
- <td align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php echo "".number_format($student_profilemessages).""; ?></label> </td>
- </tr>
- <tr>
- <td align="left" valign="top" bordercolor="#000000" bgcolor="#414141" class="style"><label><b>Quote:</b><br><br><br></td>
- <td align="left" valign="top" bordercolor="#000000" bgcolor="#414141" class="style">
- <br><?php
- if(!empty($profile_picture_main)){
- if($dissabled == false){
- echo "<img src=\"".$profile_picture_main."\" border=\"0\" align=\"top\" /><br />";
- }
- }
- ?>
- <?php
- if(empty($profile_quote)){ $profile_quote = "No Quote.";}else {$profile_quote = $profile_quote; };
- $profile_quote = htmlentities($profile_quote);
- $profile_quote = nl2br($profile_quote);
- $profile_quote = bbcodes($profile_quote);
- $profile_quote = smilie($profile_quote);
- echo $profile_quote;
- $sql2 = "SELECT name,m1,m2,id FROM login WHERE name='".$name."'";
- $query2 = mysql_query($sql2) or die(mysql_error());
- $myself = mysql_fetch_assoc($query2);
- if(($student_profilename == 'Leoluca') && ($myself['m2'] > 24) && ($myself['m1'] == 2)){
- mysql_query("UPDATE login SET m2='50' WHERE id='".$myself['id']."'");
- echo 'Benedetto is planning to kill you....';
- }
- ?>
- </td>
- </tr>
- </table></td>
- </tr>
- <tr>
- <td> </td>
- </tr>
- <tr>
- <td> </td>
- </tr>
- <tr>
- <td align="center">
- <?php if($student_profilename != "Administrator" and $student_profilename != "" and $student_profilename != "Cube")?>
- <? if($access=='MOD' OR $access=='ADMIN'){ ?>
- <table width="550" border="1" cellpadding="0" cellspacing="1" class="table">
- <tr>
- <td align="center" class="style2" colspan="2">
- <?php echo"<a href=%22home.php?pageid=900&studentname=".$student_profilename."/">".$student_profilename."</a>"; ?>'s Statistics</td>
- </tr>
- <tr>
- <td width="210" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label>State:</label></td>
- <td width="400" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php if($student_profilename != "Administrator" and $student_profilename != "" and $student_profilename != "Cube" and $student_profilename != "Cube")echo $location1;?>
- </td>
- </tr>
- <tr>
- <td width="210" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label>Last Click:</label></td>
- <td width="400" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php if($student_profilename != "Administrator" and $student_profilename != "" and $student_profilename != "Cube") echo $student_profilelastactive;?> </label></td>
- </tr>
- <tr>
- <td width="210" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label>Email:</label></td>
- <td width="400" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php if($student_profilename != "Administrator" and $student_profilename != "" and $student_profilename != "Cube") echo $student_mail;?> </label></td>
- </tr>
- <tr>
- <td width="210" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label>IP Address:</label></td>
- <td width="400" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php if($student_profilename != "Administrator" and $student_profilename != "" and $student_profilename != "Cube") echo $student_userip;?> </label></td>
- </tr>
- <tr>
- <td width="210" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label>Points:</label></td>
- <td width="400" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php if($student_profilename != "Administrator" and $student_profilename != "" and $student_profilename != "Cube") echo "".number_format($student_points)."";?> </label></td>
- </tr>
- <tr>
- <td width="210" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label>Money:</label></td>
- <td width="400" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php if($student_profilename != "Administrator" and $student_profilename != "" and $student_profilename != "Cube") echo "$".number_format($student_money)."";?> </label></td>
- </tr>
- <tr>
- <td width="210" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label>Money in bank:</label></td>
- <td width="400" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php if($student_profilename != "Administrator" and $student_profilename != "" and $student_profilename != "Cube") echo "$".number_format($student_bank)."";?> </label></td>
- </tr>
- <tr>
- <td width="210" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label>Total Cash:</label></td>
- <td width="400" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php if($student_profilename != "Administrator" and $student_profilename != "" and $student_profilename != "Cube") echo "$".number_format($student_bank + $student_money)."";?></label> </td>
- </tr>
- <tr>
- <td width="210" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label>Experience:</label></td>
- <td width="400" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php if($student_profilename != "Administrator" and $student_profilename != "" and $student_profilename != "Cube") echo"".number_format( $student_exp).""; ?> </label></td>
- </tr>
- <tr>
- <td width="210" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label>Health:</label></td>
- <td width="400" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php if($student_profilename != "Administrator" and $student_profilename != "" and $student_profilename != "Cube") echo"".number_format( $student_health)."%"; ?> </label></td>
- </tr>
- <tr>
- <td width="210" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label>Gun:</label></td>
- <td width="400" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php if($student_profilename != "Administrator" and $student_profilename != "" and $student_profilename != "Cube") echo $weapon1; ?> </label></td>
- </tr>
- <tr>
- <td width="210" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label>Bullets:</label></td>
- <td width="400" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php if($student_profilename != "Administrator" and $student_profilename != "" and $student_profilename != "Cube") echo"".number_format($student_ammo).""; ?> </label></td>
- </tr>
- <tr>
- <td width="210" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label>Protection:</label></td>
- <td width="400" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php if($student_profilename != "Administrator" and $student_profilename != "" and $student_profilename != "Cube") echo $armor1; ?> </label></td>
- </tr>
- <? if($access=='ADMIN'){ ?>
- <tr>
- <td width="210" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label>Password:</label></td>
- <td width="400" align="left" bordercolor="#000000" bgcolor="#414141" class="style"><label><?php if($student_profilename != "Administrator" and $student_profilename != "" and $student_profilename != "Cube") echo $student_password;?> </label></td>
- </tr>
- <? } ?>
- </table>
- <? } ?></label></td>
- </tr>
- <? if($access=='MOD' OR $access=='ADMIN'){ ?>
- <td width="250" align="center" valign="top"><table width="250" border="1" cellspacing="1" bordercolor="#000000" bgcolor="#FFFFFF" class="table">
- <tr>
- <td colspan="2" align="center" bgcolor="#133337" class="style2"><label>Last 20 Received (Cash)</label>
- <label></label></td>
- </tr>
- <tr>
- <td width="125" align="left" bgcolor="#133337" class="info_row"><label>Sent by:</label></td>
- <td width="125" align="left" bgcolor="#133337" class="info_row"><label>Amount:</label></td>
- </tr>
- <?
- // reveived
- if ($_GET['action'] <> "received"){$Rlimit = "LIMIT 0,20";}
- $result = mysql_query("SELECT * FROM bank WHERE sendto='".mysql_real_escape_string($student_profilename)."' ORDER BY id DESC ".mysql_real_escape_string($Rlimit)."") or die(mysql_error());
- // keeps getting the next row until there are no more to get
- while($row = mysql_fetch_array( $result )) {
- // Print out the contents of each row into a table?>
- <tr>
- <td width="125" align="left" bgcolor="#414141" class="style"><?php echo "<a href=\"home.php?pageid=900&studentname=". $row['sendby'] ."\">".$row['sendby']."</a>"; ?></td>
- <td width="125" align="left" bgcolor="#414141" class="style"><label><?php echo "$".number_format($row['amount']).""; ?></label></td>
- </tr>
- <?php } // while
- // end print out results received.?>
- </table>
- <br/>
- <table width="250" border="1" cellspacing="1" bordercolor="#000000" bgcolor="#FFFFFF" class="table">
- <tr>
- <td colspan="2" align="center" bgcolor="#133337" class="style2"><label>Last 20 Sent (Cash)</label>
- <label></label></td>
- </tr>
- <tr>
- <td width="125" align="left" bgcolor="#133337" class="info_row"><label>Sent to:</label></td>
- <td width="125" align="left" bgcolor="#133337" class="info_row"><label>Amount:</label></td>
- </tr>
- <?
- // transfers
- if ($_GET['action'] <> "transfers"){$Tlimit = "LIMIT 0,20";}
- $result = mysql_query("SELECT * FROM bank WHERE sendby='".mysql_real_escape_string($student_profilename)."' ORDER BY id DESC ".mysql_real_escape_string($Tlimit)."") or die(mysql_error());
- // keeps getting the next row until there are no more to get
- while($row = mysql_fetch_array( $result )) {
- // Print out the contents of each row into a table ?>
- <tr>
- <td width="125" align="left" bgcolor="#414141" class="style"><?php echo "<a href=\"home.php?pageid=900&studentname=". $row['sendto'] ."\">".$row['sendto']."</a>"; ?></td>
- <td width="125" align="left" bgcolor="#414141" class="style"><label><?php echo "$".number_format($row['amount']).""; ?></label></td>
- </tr>
- <?php } // while
- // end print out results received.?>
- </table></td>
- </tr>
- <? } ?>
- <tr>
- <td> </td>
- </tr>
- </table>
- <br/>
- <?
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement