Hi, I tried to post this question severl times your forum gives a debug mode error , I am not sure if there is any problems with long posts triggers the error
No way it doesnt accept my post, here is the error
Line : 282
File : functions_post.php
It must be something to do with the format, I am surprised that a coporate site like this is using a free platform such as PHPbb
You can email the error to me, my username @ flightaware.com
Email sent with the error, please get me some answers to my questions if you can
The forums error you received is caused by attempting to submit non-ASCII characters. In this case it looks like the ellipsis was converted from 3 normal periods to a single ellipsis character and one of the single quotes was converted into a stylized version. Sometimes document editors like Word will do those replacements; it’s best to compose your post in your web browser.
1- looking to how airports list flights
gtaa.com/en/travellers/searc … tting=true
They seem to by using different codes, so Aircanada is AC while It is ACA in your system, why your system doesn’t accept the flight codes as used in Pearson Airport official site.
Same applies to airports … YYZ is Pearson airport code which people know, why it is CYYZ on your site.
The two letter airline codes and three letter airport codes are IATA codes (used by the airlines).
The three letter airline codes and four letter airport codes are ICAO codes (used by air traffic control).
Being more closely integrated with air traffic control than the airlines, we use ICAO codes for all of our data, although we do support IATA codes in some parts of the web interface.
2- There is far more detailed information available here flightaware.com/live/flight/ACA540 than what is in the API (i.e. time left for the flight, Aircraft details)
The time left for the flight is the difference between the estimated arrival time (provided by FlightXML) and the current time. Aircraft details are produced from our own in-house database derived from various publications.
3- Is there a way to pull the longitude and magnitude of the departure, landing and current position for each flight so I can use it in a map
You can use the GetLastTrack method to get the entire track so far.
4- What is the time format used here?? [filed_time] => 1254841549 … is it linux.
The times are all POSIX time (also known as Unix time), the number of seconds since 1 January 1970 UTC.
5- How to use MapFlight_Beta … is this the right way to do it $result1 = $soap->MapFlight_Beta(‘ACA540’); … if so how to decode it using PHP and show it in my application.
There’s a PHP function to handle base64 decoding.
Thanks, I am tring the PHP thing but it doenst seem to work, do I need active flight to show it
$result1 = $soap->MapFlight_Beta(‘ACA540’);
$result1 = base64_decode($result1);
echo “<img src="$result1" border="0" alt="" />”;
Please advice
You’d need to write out the result of the base64 decoding to a file if you want to source it in a web page like that.
Or IMG SRC a PHP program that makes the base64 request and emits the data.
no luck, I have created a new file trm.php with the content below:
<?php
require_once('SOAP/Client.php');
$DirectFlight_Authentication = array(
'user' => 'wisam',
'pass' => '',
);
$wsdl_url = 'http://flightaware.com/commercial/flightxml/data/wsdl1.xml';
$WSDL = new SOAP_WSDL($wsdl_url,$DirectFlight_Authentication);
$soap = $WSDL->getProxy();
$result1 = $soap->MapFlight_Beta('ACA435', 1, 1);
$result2 = base64_decode($result1);
echo $result2 ;
php?>
Then tried this:
Did not workl
I’m not very familiar with PHP, but I bet you need to use a header() command or similar to send a content-type so that it’s sent as an image rather than plaintext/HTML.
The time left for the flight is the difference between the estimated arrival time (provided by FlightXML) and the current time.
Fine but in this case I need to check the time in the destination airport to be able to do the math, also why you do not simply provide this in the API output, is there a way to do it through another query??
I am trying to build an application for users and I have two issues so far:
1- you do not use the same airport codes used by biggest airports(check www.gtaa.com), I need to use my app to fix the codes before passing it to your API, so pleas provide what codes you are accepting VS what airports using in their dashboards.
2- Confirm if you can pass the time left which will save me a lot of programming work, or at least provide the time in the destination airport in the API
Thanks
The times in FlightXML are not localized; they’re all UTC. If you don’t know the timezone at an airport you can use the AirportInfo method to obtain it.
We accept ICAO airport codes. Wikipedia has a mostly complete list. I can’t find a readily available authoritative list from ICAO.
You can determine the time remaining from the difference between the current UTC time (available from time()) and the estimated arrival time provided by FlightXML.
FWIW, the 4-character ICAO codes that FlightAware uses are more complete, each code is unique, and it is used in far more places than the 3-character IATA codes.