-
Posts
138 -
Joined
-
Last visited
Content Type
Profiles
Forums
phpVMS Resources
Downloads
Everything posted by faraz
-
Thank you vangelisb I want show Recent Reports in new page . similar to http://www.linkvirtual.info/phpvms/ (Recent Flights)
-
HI How Can I Flight Type ? I want add charter flight . when pilot send PIREP , charter flight automatically delete from schedules.
-
Please see below code : <center><h2>Recent Arrivals</h2> <?php if(!$reports) { echo 'No reports have been filed';return; } echo "<table border="0.2" width="60%"><tr> <td align="center"><b>Fl. Number</b></td> <td align="center"><b>Pilot Name</b></td> <td align="center"><b>From</b></td> <td align="center"><b>To</b></td> <td align="center"><b>Aircraft</b></td> <td align="center"><b>Status</b></td></tr>"; foreach($reports as $report) { echo "<tr> <td bgcolor=#EBEEEF width=5% height=5 align=left><font face=Verdana color=#7E7E7E size=1<td>$report->code $report->flightnum </td> <td bgcolor=#EBEEEF width=10% height=5 align=left><font face=Verdana color=#7E7E7E size=1<td>$report->firstname $report->lastname</td> <td bgcolor=#EBEEEF width=5% height=5 align=left><font face=Verdana color=#7E7E7E size=1<td>$report->depicao</td> <td bgcolor=#EBEEEF width=5% height=5 align=left><font face=Verdana color=#7E7E7E size=1<td>$report->arricao</td> <td bgcolor=#EBEEEF width=5% height=5 align=left><font face=Verdana color=#7E7E7E size=1<td>$report->aircraft</td> <td bgcolor=#EBEEEF width=5% height=5 align=left><font face=Verdana color=#7E7E7E size=1<td>Landed</td></tr>"; } echo '</table>'; ?></center> when I insert that code in new page , Parse error: syntax error, unexpected T_LNUMBER, expecting ',' or ';' in /home/xxx/public_html/core/pages/test.htm on line 12
-
I didn't change any code . /** * Get the total number of flights flown */ public static function TotalFlights($airline_code = '') { $sql = 'SELECT COUNT(*) AS `total` FROM `'.TABLE_PREFIX.'pireps` WHERE `accepted`='.PIREP_ACCEPTED; if($airline_code != '') { $sql .= " AND `code`='{$airline_code}' GROUP BY `code`"; } $result = DB::get_row($sql); if(!$result) { return 0; } return $result->total; } /** * Get the top routes */ public static function TopRoutes($airline_code='') { $sql = 'SELECT * FROM `'.TABLE_PREFIX.'schedules`'; if($airline_code != '') { $sql .= " AND `code`='{$airline_code}' GROUP BY `code`"; } $sql =' ORDER BY `timesflown` DESC LIMIT 10'; return DB::get_results($sql); } <strong>Total Hours Flown: </strong><?php echo StatsData::TotalHours($airline_code = 'UAE'); ?><br />
-
Does anyone have any idea how i fix it?
-
HI when I created 3more Airlines , Total Hours Flown and Total Flight Today stop working. In Reports page (Admin): VA Stats: At a Glance Total Pilots: 10 Total Flights: 18 Total Hours Flown: Total Miles Flown: 7980 Total Fuel Burned: 225404 Total Flight Today: 0 Total PAX Carried: 3499 Stats for SAS Total Pilots: 2 Total Flights: 13 Total Hours Flown: Total Miles Flown: 5834 Total Fuel Burned: 189907 Total Flight Today: 0 Total PAX Carried: 2950
-
HI I added below code in new page, but it doesn't work : <center><h2>Recent Arrivals</h2> <?php if(!$reports) { echo 'No reports have been filed';return; } <table border="0.5" width="100%"> <td align=center><b>FL.Number</b></td> <td align=center><b>Pilot Name</b></td> <td align=center><b>From</b></td> <td align=center><b>To</b></td> <td align=center><b>Aircraft</b></td> <td align=center><b>Status</b></td>"; foreach($reports as $report) { <td bgcolor=#EBEEEF width=5% height=5 align=left><font face=Verdana color=#7E7E7E size=1<td>$report->code $report->flightnum </td> <td bgcolor=#EBEEEF width=10% height=5 align=left><font face=Verdana color=#7E7E7E size=1<td>$report->firstname $report->lastname</td> <td bgcolor=#EBEEEF width=5% height=5 align=left><font face=Verdana color=#7E7E7E size=1<td>$report->depicao</td> <td bgcolor=#EBEEEF width=5% height=5 align=left><font face=Verdana color=#7E7E7E size=1<td>$report->arricao</td> <td bgcolor=#EBEEEF width=5% height=5 align=left><font face=Verdana color=#7E7E7E size=1<td>$report->aircraft</td> <td bgcolor=#EBEEEF width=5% height=5 align=left><font face=Verdana color=#7E7E7E size=1<td>Landed</td>; } </table> ?></center> Parse error: syntax error, unexpected '<' in /home/xx/public_html/xxx/core/pages/test2.htm on line 12
-
Thank You very much nabeel After 3-4 days , Pilot roster fully work . Tnx
-
HI How can I show Fleet by airlines ?
-
HI are you sure this code is correct ? 'p.airline' and also I try 'p.code' , but those are not working . and I think below link doesn't exist in PilotData : PilotData::findPilots(array('p.airline'=>$airline->codes));
-
HI Can I use Air Tv for FSFK with phpvms ? If yes , How can I setup Air Tv with phpvms . Tnx
-
I added DB::debug(); . public function index() { $allairlines = OperationsData::getAllAirlines(); DB::debug(); if(!$allairlines) $allairline = array(); foreach($allairlines as $airline) { $this->set('title', $airline->name); $this->set('code', $airline->code); $this->set('allpilots', PilotData::findPilots(array('p.airline'=>$airline->code))); $this->render('pilots_list.tpl'); } $noAirline = PilotData::findPilots(array('p.airline'=>'')); if(!$noairline) { return; } $this->set('title', 'No Airlines'); $this->set('code', ''); $this->set('allpilots', $noairlines); $this->render('pilots_list.tpl'); } and pilots_list <h3><?php echo $title.'-'.$code?></h3> <thead> <table border="0.5" width="100%"><tr> <tr> <th bgcolor=#F2F2F2>Pilot ID</th> <th bgcolor=#F2F2F2>Name</th> <th bgcolor=#F2F2F2>Rank</th> <th bgcolor=#F2F2F2>Location</th> <th bgcolor=#F2F2F2>IVAO VID</th> </thead> <tbody> <?php foreach($roster as $pilot) { /* To include a custom field, use the following example: <td> <?php echo PilotData::GetFieldValue($pilot->pilotid, 'VATSIM ID'); ?> </td> For instance, if you added a field called "IVAO Callsign": echo PilotData::GetFieldValue($pilot->pilotid, 'IVAO Callsign'); */ ?> <tr> <td bgcolor=#FFFFFF width=10% height=5 align=center><font face=Tahoma color=#7E7E7E size=2><a href="<?php echo url('/profile/view/'.$pilot->pilotid);?>"> <?php echo PilotData::GetPilotCode($pilot->code, $pilot->pilotid)?></a> </td> <td bgcolor=#FFFFFF width=20% height=5 align=center> <?php echo $pilot->firstname.' '.$pilot->lastname?> (<?php echo PilotData::getFieldValue($pilot->pilotid,'VA Rank'); ?>) </td> <td bgcolor=#FFFFFF width=10% height=5 align=center><font face=Tahoma color=#7E7E7E size=2><img src="<?php echo $pilot->rankimage?>" alt="<?php echo $pilot->rank;?>" /></td> </td> ?> <td bgcolor=#FFFFFF width=5% height=5 align=center><font face=Tahoma color=#7E7E7E size=2><?php $last_location = PIREPData::getLastReports($pilot->pilotid, 1, PIREP_ACCEPTED); if(!$last_location) echo $pilot->hub; else echo $last_location->arricao ; ?> </td> <td bgcolor=#FFFFFF width=5% height=5 align=center><font face=Tahoma color=#7E7E7E size=2><?php $fieldvalue = PilotData :: getFieldValue ( $pilot-> pilotid , 'IVAO VID' ); if( $fieldvalue != '' ) { echo '<a href="http://www.ivao.aero/members/person/details.asp?ID='. $fieldvalue . '" target="_blank"><img src="http://status.ivao.aero/R/'.$fieldvalue.'.png" width="150" height="30" border="0" alt="IVAO VID"/></a>' ; } ?> </td> </td> <?php } ?> </tbody> </table> and still show " There are no pilots!" , where can I found output for Debug ? Tnx
-
Does anyone have any idea how i would do this?
-
HI when I flight with FSFK , Live map "Status" just show En route . Tnx
-
HI I have problem with FSFK . In Pireps just show images name : Flight Images Route Map flightmap Route Weather flightmapweather Taxi Out Path flightmaptaxiout Taxi In Path flightmaptaxiin Vertical Profile flightmapverticalprofile Landing Profile flightmaplandingprofile local.config Config::Set('FSFK_FTP_SERVER', 'ftp://xxx/public_html/data4/lib/fsfk'); Config::Set('FSFK_FTP_PORT', '21'); Config::Set('FSFK_FTP_USER', 'xxx'); Config::Set('FSFK_FTP_PASS', 'xxxx'); Config::Set('FSFK_FTP_PASSIVE_MODE', 'TRUE'); Config::Set('FSFK_IMAGE_PATH', '/data4/lib/fsfk'); // web path from SITE_ROOT I created fsfk folder in lib/fsfk and lib/images . all images upload in lib/fsfk correctly , but in Pireps now showing .
-
Please see below link : (pilot roster output ) and for Debug , you need Log ? Tnx
-
still show Airlines Name and show There are no pilots! pilots_list.tpl <h3><?php echo $title.'-'.$code?></h3> <thead> <table border="0.5" width="100%"><tr> <tr> <th bgcolor=#F2F2F2>Pilot ID</th> <th bgcolor=#F2F2F2>Name</th> <th bgcolor=#F2F2F2>Rank</th> <th bgcolor=#F2F2F2>Last Active</th> <th bgcolor=#F2F2F2>Location</th> <th bgcolor=#F2F2F2>IVAO VID</th> </thead> <tbody> <?php foreach($roster as $pilot) { /* To include a custom field, use the following example: <td> <?php echo PilotData::GetFieldValue($pilot->pilotid, 'VATSIM ID'); ?> </td> For instance, if you added a field called "IVAO Callsign": echo PilotData::GetFieldValue($pilot->pilotid, 'IVAO Callsign'); */ ?> <tr> <td bgcolor=#FFFFFF width=10% height=5 align=center><font face=Tahoma color=#7E7E7E size=2><a href="<?php echo url('/profile/view/'.$pilot->pilotid);?>"> <?php echo PilotData::GetPilotCode($pilot->code, $pilot->pilotid)?></a> </td> <td bgcolor=#FFFFFF width=20% height=5 align=center> <?php echo $pilot->firstname.' '.$pilot->lastname?> (<?php echo PilotData::getFieldValue($pilot->pilotid,'VA Rank'); ?>) </td> <td bgcolor=#FFFFFF width=10% height=5 align=center><font face=Tahoma color=#7E7E7E size=2><img src="<?php echo $pilot->rankimage?>" alt="<?php echo $pilot->rank;?>" /></td> </td> <td bgcolor=#FFFFFF width=10% height=5 align=center><font face=Tahoma color=#7E7E7E size=2><?php echo $pilot->lastlogin?></td> <td bgcolor=#FFFFFF width=5% height=5 align=center><font face=Tahoma color=#7E7E7E size=2><?php $last_location = PIREPData::getLastReports($pilot->pilotid, 1, PIREP_ACCEPTED); if(!$last_location) echo $pilot->hub; else echo $last_location->arricao ; ?> </td> <td bgcolor=#FFFFFF width=5% height=5 align=center><font face=Tahoma color=#7E7E7E size=2><?php $fieldvalue = PilotData :: getFieldValue ( $pilot-> pilotid , 'IVAO VID' ); if( $fieldvalue != '' ) { echo '<a href="http://www.ivao.aero/members/person/details.asp?ID='. $fieldvalue . '" target="_blank"><img src="http://status.ivao.aero/R/'.$fieldvalue.'.png" width="150" height="30" border="0" alt="IVAO VID"/></a>' ; } ?> </td> </td> <?php } ?> </tbody> </table> and pilot.php public function index() { $allairlines = OperationsData::getAllAirlines(); if(!$allairlines) $allairline = array(); foreach($allairlines as $airline) { $this->set('title', $airline->name); $this->set('code', $airline->code); $this->set('allpilots', PilotData::findPilots(array('p.airline'=>$airline->code))); DB::debug(); $this->render('pilots_list.tpl'); } $noAirline = PilotData::findPilots(array('p.airline'=>'')); if(!$noairline) { return; } $this->set('title', 'No Airlines'); $this->set('code', ''); $this->set('allpilots', $noairlines); $this->render('pilots_list.tpl'); }
-
sorry I don't understand . what do you mean ?
-
HI I have same problem . If I delete Aircraft, it will also delete all report with that aircraft . and I have same problem with flight plane. and if I change Aircraft registration , it will also change all reports with that registration . I think all data are variable in phpvms and new data replace with old data. if you can change to fix data ,all problem will solve . (create a table for aircraft deleted and ... )
-
Log : Caller: DB::write_debug->DB::query public function index() { $allairlines = OperationsData::getAllAirlines(); if(!$allairlines) $allairline = array(); foreach($allairlines as $airline) { $this->set('title', $airline->name); $this->set('code', $airline->code); $this->set('allpilots', PilotData::findPilots(array('p.airline'=>$airline->code))); DB::debug(); $this->render('pilots_list.tpl'); } $noAirline = PilotData::findPilots(array('p.airline'=>'')); if(!$noairline) { return; } $this->set('title', 'No Airlines'); $this->set('code', ''); $this->set('allpilots', $noairlines); $this->render('pilots_list.tpl'); }
-
it doesn't work . Parse error: syntax error, unexpected T_VARIABLE in /home/XXX/public_html/data4/core/modules/Pilots/Pilots.php on line 36 { $allairlines = OperationsData::getAllAirlines(); if(!$allairlines) $allairline = array(); foreach($allairlines as $airline) { $this->set('title', $airline->name); $this->set('code', $airline->code); $this->set('allpilots', PilotData::findPilots(array('p.airline'=>$airline->code))); DB::debug() $this->render('pilots_list.tpl'); } $noAirline = PilotData::findPilots(array('p.airline'=>'')); if(!$noairline) { return; } $this->set('title', 'No Airlines'); $this->set('code', ''); $this->set('allpilots', $noairlines); $this->render('pilots_list.tpl'); }
-
HI thank You nabel for help! still show Airlines name in Pilot roster . KLM : there are no pilot . { // Get all of our hubs, and list pilots by hub $allairlines = OperationsData::getAllAirlines(); if(!$allairlines) $allairline = array(); foreach($allairlines as $airline) { $this->set('title', $airline->name); $this->set('code', $airline->code); $this->set('allpilots', PilotData::findPilots(array('p.airline'=>$airline->code))); $this->render('pilots_list.tpl'); } $noAirline = PilotData::findPilots(array('p.airline'=>'')); if(!$noairline) { return; } $this->set('title', 'No Airlines'); $this->set('code', ''); $this->set('allpilots', $noairlines); $this->render('pilots_list.tpl'); }
-
please check below code : $allairlines = OperationsData::getAllAirlines(); if(!$allairlines) $allairline = array(); foreach($allairlines as $airline) { $this->set('title', $airline->name); $this->set('code', $airline->code); $this->set('allpilots', PilotData::findPilots(array('p.Airline'=>$airline->code))); $this->render('pilots_list.tpl'); } $noAirline = PilotData::findPilots(array('p.Airline'=>'')); if(!$noairline) { return; } $this->set('title', 'No Airlines'); $this->set('code', ''); $this->set('allpilots', $noairlines); $this->render('pilots_list.tpl'); } and just show Airline name .
-
HI Now pilot roster show pilots by Hub , I want show pilots by Airline . I try to change pilot.php , but just show Airlines Name nad Code . "There are no pilots!" $allairlines = OperationsData::getAllAirlines($onlyenabled=false); if(!$allairlines) $allairline = array(); foreach($allairlines as $airline) { $this->set('title', $airline->name); $this->set('code', $airline->code); $this->set('allpilots', PilotData::findPilots(array('p.code'=>$airline->code))); $this->render('pilots_list.tpl'); } $noairlines = PilotData::findPilots(array('p.code'=>'')); if(!$noairline) { return; } $this->set('title', 'No Airlines'); $this->set('code', ''); $this->set('allpilots', $noairlines); $this->render('pilots_list.tpl'); } Tnx
-
Hi Joeri Are you try FSFK with 869 ? I have problem with Live ACARS system in FSFk .