Jump to content

Curshad

Members
  • Posts

    175
  • Joined

  • Last visited

  • Days Won

    3

Everything posted by Curshad

  1. <p>Dear <?php echo Auth::$userinfo->firstname.' '.Auth::$userinfo->lastname; ?>,</p> You are required to submit one PIREP per month. Your last PIREP was sent on <?php echo Auth::$userinfo->lastpirep?>.</p> Please be advised if you do not send a report within the next 2 days your account will be deleted. Sincerely SkyBahamas Virtual - Administrative Staff Anyone knows how i can correct that? like i said it sends my name to the person Im sending the warning to.
  2. sorry is this covered? i want to display the top 10 landing rates of the current month here http://skybahamasvirtual.net/index.php/TouchdownStats So i don't want that full table i just wanna replace all codes with what needs to be added in an taken out. I don't want to take out or add in the wrong info So i do apologies if i asked for a bit too much. This is the Template: <h2>Top 10 Landings for <?php echo date("F Y");?> NOTE* Landing Rates -600 and Below were not accepted</h2> <br> <br> <br> <?php //simpilotgroup addon module for phpVMS virtual airline system // //simpilotgroup addon modules are licenced under the following license: //Creative Commons Attribution Non-commercial Share Alike (by-nc-sa) //To view full license text visit http://creativecommons.org/licenses/by-nc-sa/3.0/ // //@author David Clark (simpilot) //@copyright Copyright (c) 2009-2010, David Clark //@license http://creativecommons.org/licenses/by-nc-sa/3.0/ ?> <table width="700" border="1" cellspacing="1" cellpadding="1"> <tr> <th>Pilot</th> <th>Aircraft</th> <th>Arrival Field</th> <th>Landing Rate</th> <th>Date Flown</th> </tr> <?php foreach($stats as $stat) { $pilot = PilotData::getPilotData($stat->pilotid); $aircraft = OperationsData::getAircraftInfo($stat->aircraft); echo '<tr>'; echo '<td>'.PilotData::getPilotCode($pilot->code, $pilot->pilotid).' - '.$pilot->firstname.' '.$pilot->lastname.'</td>'; echo '<td align="center">'.$aircraft->fullname.'</td>'; echo '<td align="center">'.$stat->arricao.'</td>'; echo '<td align="center">'.$stat->landingrate.'</td>'; echo '<td align="center">'.date(DATE_FORMAT, strtotime($stat->submitdate)).'</td>'; echo '</tr>'; } ?> This is the TouchdownStatsData.class.php <?php //simpilotgroup addon module for phpVMS virtual airline system // //simpilotgroup addon modules are licenced under the following license: //Creative Commons Attribution Non-commercial Share Alike (by-nc-sa) //To view full license text visit http://creativecommons.org/licenses/by-nc-sa/3.0/ // //@author David Clark (simpilot) //@copyright Copyright (c) 2009-2010, David Clark //@license http://creativecommons.org/licenses/by-nc-sa/3.0/ class TouchdownStatsData extends CodonData { public function get_all_stats() { $query = "SELECT pilotid, code, flightnum, depicao, arricao, aircraft, landingrate, submitdate FROM `".TABLE_PREFIX."pireps` WHERE landingrate < '0' ORDER BY landingrate DESC"; return DB::get_results($query); } public function get_stats($howmany) { $query = "SELECT pilotid, code, flightnum, depicao, arricao, aircraft, landingrate, submitdate FROM `".TABLE_PREFIX."pireps` WHERE landingrate < '0' ORDER BY landingrate DESC LIMIT $howmany"; return DB::get_results($query); } public function get_airline_stats($airline) { $query = "SELECT * FROM `".TABLE_PREFIX."pireps` WHERE landingrate < '0' AND code = '$airline' ORDER BY landingrate DESC"; return DB::get_results($query); } public function get_worst_stats($howmany) { $query = "SELECT pilotid, code, flightnum, depicao, arricao, aircraft, landingrate, submitdate FROM `".TABLE_PREFIX."pireps` WHERE landingrate < '0' ORDER BY landingrate ASC LIMIT $howmany"; return DB::get_results($query); } public function get_stats_by_aircraft($aircraftId) { $query = "SELECT pilotid, code, flightnum, depicao, arricao, aircraft, landingrate, submitdate FROM `".TABLE_PREFIX."pireps` WHERE landingrate < '0' AND aircraft = $aircraftId ORDER BY landingrate DESC"; return DB::get_results($query); } public function pilot_stats($pilotid) { $query = "SELECT pilotid, code, flightnum, depicao, arricao, aircraft, landingrate, submitdate FROM `".TABLE_PREFIX."pireps` WHERE landingrate < '0' AND pilotid = '$pilotid' ORDER BY landingrate DESC"; return DB::get_results($query); } public function pilot_average($pilotid) { $stats = self::pilot_stats($pilotid); $total = 0; $count = 0; if(!empty($stats)) { foreach ($stats as $stat) { $total = $total + $stat->landingrate; $count++; } return $total / $count; } else {return '0';} } public function airline_average() { $stats = self::get_all_stats(); $total = 0; $count = 0; foreach ($stats as $stat) { $total = $total + $stat->landingrate; $count++; } $average = $total / $count; return $average; } } This is the TouchdownStats.php <?php //simpilotgroup addon module for phpVMS virtual airline system // //simpilotgroup addon modules are licenced under the following license: //Creative Commons Attribution Non-commercial Share Alike (by-nc-sa) //To view full license text visit http://creativecommons.org/licenses/by-nc-sa/3.0/ // //@author David Clark (simpilot) //@copyright Copyright (c) 2009-2010, David Clark //@license http://creativecommons.org/licenses/by-nc-sa/3.0/ class TouchdownStats extends CodonModule { public function index() { $this->set('stats', TouchdownStatsData::get_all_stats()); $this->show('touchdownstats/touchdownstats_index.tpl'); } public function top_landings($howmany) { $this->set('stats', TouchdownStatsData::get_stats($howmany)); $this->show('touchdownstats/touchdownstats_index.tpl'); } }
  3. Hey how can i tell which version of phpvms i have? So i can know which version of the pilot shop to use.
  4. I dont understand how to write a code to display what I want. I'll just tell the pilots switch it in the pilot center.
  5. Oh yeah I forgot they do. Thanks so much. Hey i apologize if I offendedid with all caps. I just came from flying in vatsim. I'm sorry sir.
  6. HI CAN I CREAT A NEW SIGNATURE AND ADD IT TO ANOTHER AIRLINE WITHIN MY VA? FOR E.G. I HAVE A CODESHARE AIRLINE SILVER AIRWAYS ITS AN ADDED AIRLINE (FROM WITHIN THE ADMIN CENTER) UNDER MY SKY BAHAMAS VIRTUAL AIRLINE. SO THE IMAGE IN MY FORUM SIGNATURE IS THE SIGNATURE FOR MY VA I WANT SIL PILOTS TO HAVE A SIMILAR ONE BUT MODDED SO THEY CAN SEE THEY ARE SIL PILOTS BUT ALSO KEEPING MY CURRENT SIGNATURE. heres the image
  7. HI CAN I CREAT A NEW SIGNATURE AND ADD IT TO ANOTHER AIRLINE WITHIN MY VA? FOR E.G. I HAVE A CODESHARE AIRLINE SILVER AIRWAYS ITS AN ADDED AIRLINE (FROM WITHIN THE ADMIN CENTER) UNDER MY SKY BAHAMAS VIRTUAL AIRLINE. SO THE IMAGE IN MY FORUM SIGNATURE IS THE SIGNATURE FOR MY VA I WANT SIL PILOTS TO HAVE A SIMILAR ONE BUT MODDED SO THEY CAN SEE THEY ARE SIL PILOTS BUT ALSO KEEPING MY CURRENT SIGNATURE.
  8. Oh Ok. I will test it out. I apologise if i seem slow. I never really went to school specifically for coding so i am learning how coding and stuff works just by making website errors and google. I try to learn as much as i can.
  9. I see so i would have to list all numbers that would probably fit a flight number? or i would have to list all available Flight # that are in my schedule?
  10. Would you mind selling a sample or a template? please?
  11. No nothing worked. In my Flight Schedules and routes in admin center the Code is SIL and when i edit. SIL- Silver Airways for SBM is SBM - SkyBahamas Virtual I dont get why code doesnt work. i know i tried this and it worked <?php if($flight->flightnum == "SIL3983") {echo "<img src='http://greenvillems.org/wp-content/uploads/2012/11/Silver-Logo.jpg' width='120' height='35'/>";} elseif($flight->flightnum == "SBM850") {echo "<img src='http://tblocations-airlinelogores.s3.amazonaws.com/200-75-4c3f16e6579e2-sky-bahamas-google-chrome-15-7-2010-160848-bmp.jpg' width='120' height='35'/>";} ?> But that is not a legit fix....
  12. You know what my Pilot ID is SBM. i bet if it changed to SIL it would of shown up. I'll test it out....
  13. Didnt notice any change. the Image loaded but no change in image.... <tr> <td align="center"><?php if($flight->phasedetail == "Boarding") { echo "<img style='padding-left:3px;' src=''>"; } elseif($flight->phasedetail == "Arrived") { echo "<img style='padding-left:3px;' src=''>"; } elseif($flight->phasedetail == "On Approach") { echo "<img style='padding-left:3px;' src=''>"; } ?></td> <td align="center"><?php if($flight->code == 'SIL') {echo '<img src="http://www.juergenbaumbusch.de/wp-content/uploads/2013/06/silver-airways.jpg" width="120" height="35"/>';} elseif($flight->code == 'SBM') {echo '<img src="http://tblocations-airlinelogores.s3.amazonaws.com/200-75-4c3f16e6579e2-sky-bahamas-google-chrome-15-7-2010-160848-bmp.jpg" width="120" height="35"/>';} ?></td> <td align="center"><?php echo $flight->flightnum;?></td> <td align="center"><?php echo $flight->depname;?></td> <td align="center"><?php echo $flight->arrname;?></td> <td align="center"><?php echo $flight->aircraftname;?></td> <td align="center"><?php if($flight->phasedetail != 'Paused') { echo $flight->phasedetail; } else { echo "Cruise"; }?></font></td> </tr>
  14. So now the Code should be: <table style="border:1px solid grey;" cellspacing="2" cellpadding="2" bgcolor="#171717"> <tr> <th align="center" style="background-color: #171717; width: 3.5%;"> </th> <th width="10%" align="center" style="background-color: #171717;">Airline</th> <th width="10%" align="center" style="background-color: #171717;">Flight</th> <th width="30%" align="center" style="background-color: #171717;">Departure</th> <th width="30%" align="center" style="background-color: #171717;">Arrival</th> <th width="5%" align="center" style="background-color: #171717;">Aircraft</th> <th width="18.5%" align="center" style="background-color: #171717;">Status</th> </tr> <?php $results = ACARSData::GetACARSData(); if (count($results) > 0) { foreach($results as $flight) { ?> <tr> <td align="center"><?php if($flight->phasedetail == "Boarding") { echo "<img style='padding-left:3px;' src=''>"; } elseif($flight->phasedetail == "Arrived") { echo "<img style='padding-left:3px;' src=''>"; } elseif($flight->phasedetail == "On Approach") { echo "<img style='padding-left:3px;' src=''>"; } ?></td> <td align="center"><?php if($flight->code == 'SIL') {echo 'the image you want to display for SIL flights';} elseif($flight->code == 'SBM') {echo 'the image you want to display for SBM flights';} ?></td> <td align="center"><?php echo $flight->flightnum;?></td> <td align="center"><?php echo $flight->depname;?></td> <td align="center"><?php echo $flight->arrname;?></td> <td align="center"><?php echo $flight->aircraftname;?></td> <td align="center"><?php if($flight->phasedetail != 'Paused') { echo $flight->phasedetail; } else { echo "Cruise"; }?></font></td> </tr> <?php } } else { ?> <tr><td width="20%" align="center" colspan="6" style="padding: 5px; font-size: 13px; font-weight: bold; color: #3399FF;">No Flights in Progress!</td></tr> <?php } ?> </table> Correct me if Im wrong.
  15. Hey guys in the Airline coloumn of my Live flight board on my home page @ http://skyabahamasvirtual.net I have and image there to display when a SBM flight is flown here is the code <table style="border:1px solid grey;" cellspacing="2" cellpadding="2" bgcolor="#171717"> <tr> <th align="center" style="background-color: #171717; width: 3.5%;"> </th> <th width="10%" align="center" style="background-color: #171717;">Airline</th> <th width="10%" align="center" style="background-color: #171717;">Flight</th> <th width="30%" align="center" style="background-color: #171717;">Departure</th> <th width="30%" align="center" style="background-color: #171717;">Arrival</th> <th width="5%" align="center" style="background-color: #171717;">Aircraft</th> <th width="18.5%" align="center" style="background-color: #171717;">Status</th> </tr> <?php $results = ACARSData::GetACARSData(); if (count($results) > 0) { foreach($results as $flight) { ?> <tr> <td align="center"><?php if($flight->phasedetail == "Boarding") { echo "<img style='padding-left:3px;' src=''>"; } elseif($flight->phasedetail == "Arrived") { echo "<img style='padding-left:3px;' src=''>"; } elseif($flight->phasedetail == "On Approach") { echo "<img style='padding-left:3px;' src=''>"; } ?></td> <td align="center"><img src="http://tblocations-airlinelogores.s3.amazonaws.com/200-75-4c3f16e6579e2-sky-bahamas-google-chrome-15-7-2010-160848-bmp.jpg" width="120" height="35" alt="<?php echo $airline->name;?>" /></td> <td align="center"><?php echo $flight->flightnum;?></td> <td align="center"><?php echo $flight->depname;?></td> <td align="center"><?php echo $flight->arrname;?></td> <td align="center"><?php echo $flight->aircraftname;?></td> <td align="center"><?php if($flight->phasedetail != 'Paused') { echo $flight->phasedetail; } else { echo "Cruise"; }?></font></td> </tr> <?php } } else { ?> <tr><td width="20%" align="center" colspan="6" style="padding: 5px; font-size: 13px; font-weight: bold; color: #3399FF;">No Flights in Progress!</td></tr> <?php } ?> </table> I have another airline added in the admin center of PHPVMS. That airline is Silver Airways. I want my flight board to display this image in the airline coloumn of the Live Flight Board when a SIL flight is flown. Would this be the correct coding do such a thing? Without removing SBM image? or in other words If i fly an SBM flight the airline colomun displays this image and if someone else flys a SIL flight the same time i Fly an SBM flight it displays both Sky Bahamas and Silver Airways image again is this the correct coding to do such a thing? <td align="center"><img src="http://tblocations-airlinelogores.s3.amazonaws.com/200-75-4c3f16e6579e2-sky-bahamas-google-chrome-15-7-2010-160848-bmp.jpg" width="120" height="35" alt="<?php echo $airline->name;?>" /><img src="http://www.juergenbaumbusch.de/wp-content/uploads/2013/06/silver-airways.jpg" width="120" height="35" alt="<?php echo $airline->name;?>" /></td> AND OR <td align="center"><img src="http://tblocations-airlinelogores.s3.amazonaws.com/200-75-4c3f16e6579e2-sky-bahamas-google-chrome-15-7-2010-160848-bmp.jpg" width="120" height="35" alt="<?php echo $airline->name;?>" /><img src="http://www.juergenbaumbusch.de/wp-content/uploads/2013/06/silver-airways.jpg" width="120" height="35" alt="Silver Airways" /></td>
  16. Thanks for that piece of information. anyone can think of a code that should work?
  17. Thanks I did not. Will try it out.
  18. Hey guys, I just recently found out that in the Pilot manager addon i have (not sure whichh version) Has my Name in emails i sent to other pilots. Here is the code let me know how i can fix. Please. <p>Dear <?php echo Auth::$userinfo->firstname.' '.Auth::$userinfo->lastname; ?>,</p> You are required to submit one PIREP per month. Your last PIREP was sent on <?php echo Auth::$userinfo->lastpirep?>.</p> Please be advised if you do not send a report within the next 2 days your account will be deleted. Sincerely SkyBahamas Virtual - Administrative Staff And as an example, lets say i email a pilot name John Sky, and i sent him a warning email it would show up as Dear Curshad Nairn, You are required to submit one PIREP per month. Your last PIREP was sent on 2013-08-18 21:33:23. Please be advised if you do not send a report within the next 2 days your account will be deleted. Sincerely SkyBahamas Virtual - Administrative Staff
  19. So lets say I gave a friend of mine a callsign as " SBM5040" (Just him only) and my regular pilots are "SBM265" (say thats the highest for norm pilots) there is so way to delete that "SBM5040" entry or to reset it back to " SBM265" or anything lower than 5040? I went and did that out of my Ignorance please tell me there is a fix ?
  20. Thanks You cant cut them to the dimension 656px width height 235 here are the links to the photos. https://fbcdn-sphotos-d-a.akamaihd.net/hphotos-ak-ash3/554796_4164535065180_1829035952_n.jpg https://fbcdn-sphotos-d-a.akamaihd.net/hphotos-ak-prn2/249433_4309193881560_1027601171_n.jpg https://fbcdn-sphotos-g-a.akamaihd.net/hphotos-ak-ash4/318256_402501186438943_2063499283_n.jpg https://fbcdn-sphotos-g-a.akamaihd.net/hphotos-ak-ash4/998524_10151397405647757_1394179765_n.jpg https://fbcdn-sphotos-h-a.akamaihd.net/hphotos-ak-frc3/580005_420143641363793_1508534736_n.jpg Thanks A lot my friend
  21. Is this free? And would you consider a freeware version basically limit available options to use and stuff like that? For example, the paid version you can choose whether you want to or don't want to award for good or bad landing rates etc. and the free version only has this one option
  22. Hey I was wondering how can I make an html slideshow or some kind of slide show addon for my website http://skybahamasvirtual.net please help if you guys can.
  23. If I purchase that website template. Can you or the simpilot group team Modify and customize it to my likings for my Virtual Airline?
×
×
  • Create New...