piaware
piaware copied to clipboard
Route information, etc.
Hello! This guy has images and route information shown directly on his piaware: https://flight.f4ipo.fr/
How could I do something like that?
The comments in his code are rather amusing... <!-- This is hideous. airframes.org insists on getting a POST with a "submit" value specified, but if we have an input control with that name then it shadows the submit() function that we need. So steal the submit function off a different form. Surely there is a better way?! -->
That code is in every flight aware instance, not just his one 😀
On Wed, Jun 16, 2021, 00:22 Brummby @.***> wrote:
The comments in his code are rather amusing...
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/flightaware/piaware/issues/72#issuecomment-861842486, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJU4T5SYNPJBO5YBWEKNYFTTS7AANANCNFSM46X3ODGQ .
Hello ! I'm "this guy" 😉 I made some custom code in order to display routes and images :
- https://flight.f4ipo.fr is hosted on a dedicated server, using ApacheHTTPd ; all static content is here, only json files are taken from a piaware instance hosted at home, increasing performance and hidding my IP, https and http/2 are some bonus. Then a reverse_proxy could be enough to get dynamic data, but aircraft.json is in fact a custom PHP page (hidden with url rewriting) : the real aircraft.js is parsed, then some data is added :
- routes and flight operator are taken in StandingData.sqb, from VirtualRadarServer : I update it daily (and of course I send updates to StandingDataMaintenance)
- additional data about plane (type, owner, ...) is from BaseStation.sqb, from a VRS instance running at home, with DataBaseWrite plugin to keep all the data, and a ADSBHub receiver : I see as much planes as possible in order to populate the database (presently 518k records !). I just keep VRS running sometimes, then push the database (I also compute it to mark military planes)
- I search for images in Flickr with its API, storing results in a third sqlite db
- planeObject.js and script.js are adapted to parse and display this additional content.
@serge-golovanow Any chance on pushing the changes in your branch up to GIT. Pretty cool modification!
@serge-golovanow I know we all hate bumps, but - are you still on this? :)
Not sure if this should be added to instances globally, since it would add an extra dependency and increase traffic to the provider(s) of route information. Making it an addon or additional package would be more appropriate in my opinion.