Jump to content

orobouros

Members
  • Content Count

    39
  • Joined

  • Last visited

Community Reputation

0 Neutral

About orobouros

  • Rank
    Advanced Member

Profile Information

  • Gender
    Male
  • Location
    France

Recent Profile Visitors

1111 profile views
  1. Hi all, here's the new skin i've made for my VA. Full screen, responsive, mega menu and many other things : http://arcadair.fr/
  2. i've made this, it works for me : <table class="Table"> <!-- entête du tableau --> <thead> <tr> <th>Division - #ligne</th> <th>Dép. ICAO</th> <th>Arr. ICAO</th> <th>Appareil</th> <th>Distance</th> <th>Prix billet</th> <th>Opérations</th> </tr> </thead> <?php $params = array( 's.code' => array ('xxx') ); $schedules = SchedulesData::findSchedules($params); foreach($schedules as $sched){ echo '<tbody>'; echo '<tr>'; echo '<td>'.$sched->code.' - '.$sched->flightnum.'</td> <td>'.$sched->depicao.'</td> <td>'.$sched->arricao.'</td> <td>'.$sched->aircraft.'</td> <td>'.ceil($sched->distance).' nm</td> <td>'.$sched->price.' €</td> <td><a href="'.SITE_URL.'/index.php/schedules/brief/'.$sched->id.'">Briefing</td>'; echo "</tr>"; } echo "</tbody>"; echo "</table>"; ?>
  3. First I've made a folder in core/modules folder with a file containing a class wich extends codonModule. Then in core/templates folder, i've written the code above in a file called by the file in core/module folder. I want an automatisation of differents lists of schedules sorted by company code, on differents pages.
  4. Hi, I want to list schedules by code, as it is in my sql request ($requete). This code is working, but i think it's not the best way to connect to database. Does another way exist to connect to database safely without writing directly username, host, password and dbname ? <table class="myTable"> <!-- entête du tableau --> <thead> <tr> <th>#ligne</th> <th>Dép. ICAO</th> <th>Arr. ICAO</th> <th>Appareil</th> <th>Distance</th> <th>Prix billet</th> <th>Opérations</th> </tr> </thead> <?php $conn = mysqli_connect('host', 'username', 'password', 'dbname'); $requete = "SELECT p.id, p.code, p.flightnum, p.depicao, p.arricao, fullname, p.distance, p.price FROM phpvms_schedules p INNER JOIN phpvms_aircraft a ON p.aircraft=a.id WHERE code='XXX'"; $res = $conn->query($requete); while ($element = mysqli_fetch_array($res)) { echo '<tbody>'; echo '<tr>'; echo '<td>'.$element['code'].' - '.$element['flightnum'].'</td> <td>'.$element['depicao'].'</td> <td>'.$element['arricao'].'</td> <td>'.$element['fullname'].'</td> <td>'.ceil($element['distance']).' nm</td> <td>'.$element['price'].' €</td> <td><a href="'.SITE_URL.'/index.php/schedules/brief/'.$element['id'].'">Briefing</td>'; echo "</tr>"; } echo "</tbody>"; echo "</table>"; ?> Thanks for helping me, Best regards
  5. Hi, I want to copy my phpvms site locally. To do this, i have proceeded like this : 1 - Export of my database. 2 - Create a new database in WAMP with phpmyadmin and import the database. 3 - Download all folders and files with Filezilla and copy this in wamp/www/phpvms_folder. After that, i've changed the following settings in local.config.php : define('DBASE_USER', 'root'); // default login of WAMP define('DBASE_PASS', ''); // default password of WAMP (no password) define('DBASE_NAME', 'db_phpvms'); // The name of my DB locally in phpMyAdmin define('DBASE_SERVER', 'localhost'); define('DBASE_TYPE', 'mysql'); define('TABLE_PREFIX', 'phpvms_'); define('SITE_URL', 'localhost/phpvms_folder'); But with this, i have this when i go in localhost/phpvms_folder i have the following errors : Is someone know where is the problem please ? Best regards
  6. orobouros

    kACARS Free v1.0.1.4

    Ok, thank you for this quick answer. I change the version on my VA website.
  7. orobouros

    kACARS Free v1.0.1.4

    Hello, i use kACARS v1.0.1.1 with no problems on the website of my VA (no problems with FS9, FSX, X-Plane and P3D except v4). But some pilots fly with P3D V4 and have this error message : These pilots try to use rhe kACARS version 1.0.1.4 with .NET 4.0 and FSUIPC5 as recommanded, but still have this issue. How can i solve this please ?
  8. Sorry for the late answer. I can't do a cron job because it's not a dedicated server. Auto cancellation seems to have a strange behaviour. I've set 48 in the local config file and it works (48 hours delay). But if i set 24 it doesn't work. So i've set 48 hours and it's ok.
  9. Hello, as we have transfered hours from our old website wich was not a phpvms, i would like to add transfer hours to the total hours. How can i do that please ?
  10. Ok, I answer to myself and for the community. If you want to unlock checkin for PIREP, you must edit the core/modules/pirep/pirep.php and erase the 7 lines after "# Only allow for valid routes to be filed" wich check if the PIREP is a scheduled flight.
  11. Hello, The pilots of my VA do many non scheduled IFR flights, in various places of the world, and a lot of VFR on the same model. It works fine with the KACARS tracker but i would like a real manual PIREP system wich allows pilots to send a PIREP of any kind with the values they choose to enter. The only condition to respect may be that each field must be filled, but i don't want to check if a scheduled flight exists, wich is the case actually. I've tried some solutions by myself but each time when i test it, it doesn't work. How can i do to allows pilot to send all PIREPS they want manually ? Here's the pirep_new.php page i've tried to modify without success : <br /><br /> <?php if(isset($message)) echo '<div id="error">'.$message.'</div>'; ?> <form action="<?php echo url('/pireps/mine');?>" method="post"> <dl> <dt>Pilot:</dt> <dd><strong><?php echo Auth::$userinfo->firstname . ' ' . Auth::$userinfo->lastname;?></strong></dd> <dt>Select Airline:</dt> <dd> <select name="code" id="code"> <option value="">Select your airline</option> <?php foreach($allairlines as $airline) { $sel = ($_POST['code'] == $airline->code || $bid->code == $airline->code)?'selected':''; echo '<option value="'.$airline->code.'" '.$sel.'>'.$airline->code.' - '.$airline->name.'</option>'; } ?> </select> </dd> <dt>Enter Flight Number:</dt> <dd><input type="text" name="flightnum" value="<?php if(isset($bid->flightnum)) { echo $bid->flightnum; }?><?php if(isset($_POST['flightnum'])) { echo $_POST['flightnum'];} ?>" /></dd> <dt>Select Departure Airport:</dt> <dd> <div id="depairport"> <select id="depicao" name="depicao"> <option value="">Select a departure airport</option> <?php foreach($allairports as $airport) { $sel = ($_POST['depicao'] == $airport->icao || $bid->depicao == $airport->icao)?'selected':''; echo '<option value="'.$airport->icao.'" '.$sel.'>'.$airport->icao . ' - '.$airport->name .'</option>'; } ?> </select> </div> </dd> <dt>Select Arrival Airport:</dt> <dd> <div id="arrairport"> <select id="arricao" name="arricao"> <option value="">Select an arrival airport</option> <?php foreach($allairports as $airport) { $sel = ($_POST['arricao'] == $airport->icao || $bid->arricao == $airport->icao)?'selected':''; echo '<option value="'.$airport->icao.'" '.$sel.'>'.$airport->icao . ' - '.$airport->name .'</option>'; } ?> </select> </div> </dd> <dt>Select Aircraft:</dt> <dd> <select name="aircraft" id="aircraft"> <option value="">Select the aircraft of this flight</option> <?php foreach($allaircraft as $aircraft) { /* Skip any aircraft which have aircraft that the pilot is not rated to fly (according to RANK) */ if(Config::Get('RESTRICT_AIRCRAFT_RANKS') === true) { /* This means the aircraft rank level is higher than what the pilot's ranklevel, so just do "continue" and move onto the next route in the list */ if($aircraft->ranklevel > Auth::$userinfo->ranklevel) { continue; } } $sel = ($_POST['aircraft'] == $aircraft->name || $bid->registration == $aircraft->registration)?'selected':''; echo '<option value="'.$aircraft->id.'" '.$sel.'>'.$aircraft->name.' - '.$aircraft->registration.'</option>'; } ?> </select> </dd> <?php // List all of the custom PIREP fields if(!$pirepfields) $pirepfields = array(); foreach($pirepfields as $field) { ?> <dt><?php echo $field->title ?></dt> <dd> <?php // Determine field by the type if($field->type == '' || $field->type == 'text') { ?> <input type="text" name="<?php echo $field->name ?>" value="<?php echo $_POST[$field->name] ?>" /> <?php } elseif($field->type == 'textarea') { echo '<textarea name="'.$field->name.'">'.$field->values.'</textarea>'; } elseif($field->type == 'dropdown') { $values = explode(',', $field->options); echo '<select name="'.$field->name.'">'; foreach($values as $value) { $value = trim($value); echo '<option value="'.$value.'">'.$value.'</option>'; } echo '</select>'; } ?> </dd> <?php } ?> <dt>Fuel Used</dt> <dd><input type="text" name="fuelused" value="<?php echo $_POST['fuelused']; ?>" /> <p>This is the fuel used on this flight in <?php echo Config::Get('LIQUID_UNIT_NAMES', Config::Get('LiquidUnit'))?></p></dd> <dt>Flight Time</dt> <dd><input type="text" name="flighttime" value="<?php echo $_POST['flighttime'] ?>" /> <p>Enter as hours - "5.30" is five hours and thirty minutes</p></dd> <dt>Route</dt> <dd><textarea name="route"><?php echo (!isset($_POST['route'])) ? $bid->route : $_POST['route']; ?></textarea> <p>Enter the route flown, or default will be from the schedule</p></dd> <dt>Comment</dt> <dd><textarea name="comment"><?php echo $_POST['comment'] ?></textarea></dd> <dt></dt> <dd><?php $bidid = ( isset($bid) )? $bid->bidid:$_POST['bid']; ?> <input type="hidden" name="bid" value="<?php echo $bidid ?>" /> <input type="submit" name="submit_pirep" value="File Flight Report" /></dd> </dl> </form> thank you by advance if you have a solution for my problem
  12. It works fine. I've tested this with 3 flights this morning and all of them are ok. A big thank you for this quick and efficient solution !
  13. I've done this modifications. It seems to work but i wait some flights from my pilots to confirm that this is not reseting number of flights to 1 as before. I give you an answer as soon as possible. Many thanks for your job and spending your time for other people.
  14. I would like the same transfer system for number of flights than for the hours with transfer. So, in the pilot profile in admin, a field to fill with transfer number of flights. Here's the original code in admin/template/pilots_details.php : <tr> <td>Total flights</td> <td><input type="text" name="totalflights" value="<?php echo $pilotinfo->totalflights;?>" /></td> </tr> <tr> <td>Total hours</td> <td><?php echo $pilotinfo->totalhours;?> <input type="hidden" name="totalhours" value="<?php echo $pilotinfo->totalhours;?>" /> </td> </tr> <tr> <td>Transfer hours</td> <td><input type="text" name="transferhours" value="<?php echo $pilotinfo->transferhours;?>" /></td> </tr> and after, the same addition in the pilot_public_profil.php, like it is for hours, where totalhours are added with transferhours : <th width="25%">Hours</font></b></th> <td width="25%"><?php echo Util::AddTime($userinfo->totalhours, $userinfo->transferhours); ?></td> It works fine for Hours, but when i try to do the same thing for flights, it goes wrong.
×
×
  • Create New...