Jump to content

Live flights board for IVAO !Released!


dimitris

Recommended Posts

A module to view the on line traffic on IVAO/VATSIM networks. One at a time you can't see both at one table. Currently data access

only from IVAO, in case you use it for VATSIM without approval you should explain them why you did it and face the consequences.

Developed and tested on:

phpVMS v2.1.934-153-g822a0b9

Please read readme.txt for instructions.

See post #17 for updated version.

Thanks!

  • Like 3
Link to comment
Share on other sites

Where does it says that I m not allowed to put an ad before a link and then use the forums linking way ? Or is there a restriction that prevent me from doing that and informing me about the "mistake" I did ?

I know soon or later someone will lock this topic and take my posting rights again but okay I know how it works...

  • Like 2
Link to comment
Share on other sites

[b]Warning[/b]:  file() [[url="http://malaysiava.org/index.php/function.file"]function.file[/url]]: URL file-access is disabled in the server configuration in [b]/home/globalai/public_html/malaysiava.org/core/modules/liveflights/liveflights.php[/b] on line [b]18[/b]

[b]Warning[/b]:  file(http://de1.www.ivao.aero/whazzup.txt) [[url="http://malaysiava.org/index.php/function.file"]function.file[/url]]: failed to open stream: no suitable wrapper could be found in [b]/home/globalai/public_html/malaysiava.org/core/modules/liveflights/liveflights.php[/b] on line [b]18[/b]

[b]Warning[/b]:  Invalid argument supplied for foreach() in [b]/home/globalai/public_html/malaysiava.org/core/modules/liveflights/liveflights.php[/b] on line [b]69[/b]  

How do I fix that?

  • Like 1
Link to comment
Share on other sites

Open liveflights.php

look around at line 9 you will see:

//randomize servers

below are some servers, just comment the server "de1" (line 13) and you are done ;)

an other (and a bit harder) way is to put some if...else statements to see if there is an error...

Also you get this:

[b]Warning[/b]:  file() [[url="http://malaysiava.org/index.php/function.file"]function.file[/url]]: URL file-access is disabled in the server configuration in [b]/home/globalai/public_html/malaysiava.org/core/modules/liveflights/liveflights.php[/b] on line [b]18[/b]

Is file access enabled to your server ?

Regards,

  • Like 1
Link to comment
Share on other sites

i've this problem:

Warning: file() [function.file]: http:// wrapper is disabled in the server configuration by allow_url_fopen=0 in /home/bluepan1/public_html/core/modules/liveflights/liveflights.php on line 18

Warning: file(http://de3.www.ivao.aero/whazzup.txt) [function.file]: failed to open stream: no suitable wrapper could be found in /home/bluepan1/public_html/core/modules/liveflights/liveflights.php on line 18

How to resolve it?

Thnx

Link to comment
Share on other sites

  • Administrators

You should be using cURL to open offsite files, allow_url_fopen creates a fairly large security risk for your site and gives even the most novice hackers an avenue to import script into your source code. allow_url_fopen is disabled by server administrators almost 100% of the time and cURL is now the standard. Nabeel has built cURL right into phpVMS to make it even easier as long as it is enabled on your server. There is no reason that any reputable host should not have cURL enabled, the free hosts are another story, as it is another reason for them to upsell you to paid hosting.

instead of;

$file = file($servers);

you could use;

$data = new CodonWebService();
$file = @$data->get($servers);

Link to comment
Share on other sites

Hi Dave! Yes you are right about the safety but the cURL is not working :/ at least my localhost and the line

extension=php_curl.dll is uncommented at my php.ini

The above result to:

Warning: Invalid argument supplied for foreach() in X:\AppServ\www\vmsdev\core\modules\liveflights\liveflights.php on line 70

Link to comment
Share on other sites

  • Administrators

Hope you dont mind, I made a few changes to your code to use curl instead of open url and also not to use GET.

Using it in this manner will save a copy of the ivao file to your own server and update it if it is more than 5 minutes old when the script looks for it.

also to get the map now use:

www.yoursite.com/index.php/liveflights/map/"ICAO OF AIRLINE YOU ARE LOOKING FOR"

I posted it at pastebin for your review -> http://pastebin.com/h8Y38yDs

Link to comment
Share on other sites

  • 4 weeks later...
  • 1 month later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...