Jump to content

Parkho

Moderators
  • Posts

    1375
  • Joined

  • Last visited

  • Days Won

    5

Everything posted by Parkho

  1. they all work just fine. Have you installed every part correctly? Also I didn't get what to amend!!
  2. Are you on free website? Cause I think your web hosting is out of service.
  3. Make a file named GetPilotData.class.php. Inside that file write the followng and save it. Now upload it into core/common folder. <?php class GetPilotData extends CodonData { public function getallpilots($limit) { $sql='SELECT * FROM phpvms_pilots ORDER BY pilotid DESC LIMIT '.intval($limit); return DB::get_results($sql); } } ?> Now in the following code <table width="40%"> <tr> <th align="center">Country (Flag) </th> <th align="center">|</th> <th align="center">Pilot ID - Pilot Name </th> <th align="center">|</th> <th align="center">HUB</th> </tr> <?php $pilotinfo = PilotData::getallpilots(); foreach($pilotinfo as $pilot) { ?> <tr> <td align ="center"><?php echo Countries::getCountryName($pilot->location);?> ( <img src="<?php echo Countries::getCountryImage($pilot->location);?>"> )</td> <td align="center">|</td> [b]<td align ="center"><a href="<?php echo url('/profile/view/'.$pilot->pilotid);?>"><?php echo $pilot->code.$pilot->pilotid.' - '.$pilot->firstname.' '.$pilot->lastname ;?></a></td>[/b] <td align="center">|</td> <td align ="center"><?php echo $pilot->hub ;?></td> </tr> <?php } ?> </table> replace this: $pilotinfo = PilotData::getallpilots(); With this: $pilotinfo = GetPilotData::getallpilots(3); 3 is the number of rows the function returns. Thanks
  4. Open core/local.config.php and find the following 3 lines. Change the width and height as desired. # Google Map Options Config::Set('MAP_WIDTH', '800px'); Config::Set('MAP_HEIGHT', '600px');
  5. Not working!!!???? Where did you upload the .js files?
  6. Pagination added to the module. Please merge the new files and pilot_manager.tpl.
  7. I used a pagination for one of my add on which I got from Google search, I can offer you that if you want.
  8. Hello, I can design a system for your new airline but would you be interested to pay for your request?
  9. I think you have used the date function and that counts the days from Jan 1st, 1970. Try using the following to calculate the days: <?php echo $pilot->lastpirep ;?>
  10. Hi All, The Pilot Manager V2.0 is now ready for download at github. Change Log: 1. Images removed and changed to buttons. 2. blank email, and edit buttons have been added. 3. The edit button will open a table where you can edit the pilot at the same page. 4. Email confirmation page has been added. Update: 5. Pagination added. Screenshots: ------------------ --------- ----------- --------
  11. Well to start off, you need to set up a module with tpl files. if you have let's say 2 airlines you'll need schedule_results.tpl and another tpl to show to your pilots at first when they open the booking page with airline selection. Then pass the value of selected airline to a function to filter out the schedules.
  12. Yes you can do that for sure but it requires a knowledge of php and html coding.
  13. Hey there, What you need is not just some codes it's actually a lot of codes and require a quiet amount of time.
  14. The error says that the system can't read the tpl files from their location cause they don't exist. Have you installed a new skin? if yes make sure the TPL files are inside the skin folder specially the header and the footer.
  15. Yes I coded it to place the new pilots at their HUB since they have no PIREPS yet and the old pilots at their last PIREP arrival airport.
  16. <table width="40%"> <tr> <th align="center">Country (Flag) </th> <th align="center">|</th> <th align="center">Pilot ID - Pilot Name </th> <th align="center">|</th> <th align="center">HUB</th> </tr> <?php $pilotinfo = PilotData::getallpilots(); foreach($pilotinfo as $pilot) { ?> <tr> <td align ="center"><?php echo Countries::getCountryName($pilot->location);?> ( <img src="<?php echo Countries::getCountryImage($pilot->location);?>"> )</td> <td align="center">|</td> [b]<td align ="center"><a href="<?php echo url('/profile/view/'.$pilot->pilotid);?>"><?php echo $pilot->code.$pilot->pilotid.' - '.$pilot->firstname.' '.$pilot->lastname ;?></a></td>[/b] <td align="center">|</td> <td align ="center"><?php echo $pilot->hub ;?></td> </tr> <?php } ?> </table>
  17. Sure there is. My PilotManager add-on.
  18. Open Finance.php in admin/modules/Finance and look for the following: $this->set('title', 'Balance Sheet for Last 3 Months');
  19. If I understood your question correctly, you want your pilots to have a pilot id like "PR002" and your flight routes are like "PAL123". For this you can add an airline in admin center with code "PR" and name "Philippine Airlines" and restrict your pilots to only use the "PR" airline at registration stage. For "PAL" all you need to do is to add your schedules with "PAL" airlines and that should do it. For restricting your pilots at registration stage open registration_mainform.tpl and find the following: <dt>Select Airline: *</dt> <dd> <select name="code" id="code"> <?php foreach($allairlines as $airline) { echo '<option value="'.$airline->code.'">'.$airline->code.' - '.$airline->name.'</option>'; } ?> </select> </dd> Then change it to the following: <dt>Select Airline: *</dt> <dd> <select name="code" id="code"> <?php foreach($allairlines as $airline) { if($airline->code == "PR") { echo '<option value="'.$airline->code.'">'.$airline->code.' - '.$airline->name.'</option>'; } } ?> </select> </dd>
×
×
  • Create New...