Missing argument 2 for ACARSData::FilePIREP(), called in /****/****/****/core/modules/wacars.php on line 42 and defined in core/common/AcarsData.class.php on line 268
Thats the response I get from the server when filing a pirep using my World ACARS program.
wacars.php:
/**
* wacars.php
* World Acars
*
* Copyright 2010 Mitchell Williamson
*
* Liscence:
* The GNU General Public License (GPL)
* Version 2, June 1991
*/
class wacars extends CodonModule
{
/**
* Receieves PIREP
* index.php/wacars/pirep
*/
public function pirep()
{
$pirep_xml = $this->post->pirepxml;
$xml = simplexml_load_string($pirep);
$aircraft = OperationsData::getAircraftByReg($xml->reg);
/** Fill the data array with data from XML */
$pirep_data = array(
'pilotid' => $xml->pilotid,
'flightnum' => $xml->flightnum,
'depicao' => $xml->depicao,
'arricao' => $xml->arricao,
'aircraft' => $aircraft->id,
'fuelused' => $xml->fuel,
'landingrate' => $xml->tdr,
'source' => 'WACARS',
'submitdate'=>'NOW()',
);
/** Submit the pirep */
$submit = ACARSData::filePIREP($pirepdata);
}
Does anyone know the solution?
Thanks,
Mitch