Jump to content

Unable to add airports (SOLVED)


peterc

Recommended Posts

After a lot of problems, and with the help of Nabeel at Fivedev, I've finally manged to install phpVMS.

Now I've come across another problem.  Whenever  I try to add airports manually I get an error "There was an error adding the airport". If I try to "look up"  an airport, the system just hangs and doesn't do anything.

I've now tried this using two different installs and with two different paid hosts. I've looked through this forum and can see that others have had the same problem in the past, but can't see any solutions to the problem.

I've been trying to get my VA set up for nearly a week now, using different platforms and hosts, so I'm getting a bit 'peeved' with all the problems,

phpVMS looks like the best platform (once you can get it working properly), so any advice on an easy 'fix' would be appreciated

Edited by peterc
Link to comment
Share on other sites

  • Moderators

Where did you download your phpVMS from? The most stable version for PHP 5.6 is this: https://github.com/DavidJClark/phpvms_5.5.x

As for the airport issue, do you have any Config::Set('PHPVMS_API_SERVER' set in your local.config.php file? If yes, what is its value? If not, add this:

Config::Set('PHPVMS_API_SERVER', 'http://api.vacentral.net');

 

Link to comment
Share on other sites

Thanks for the reply.

I haven't got a clue what version of phpVMS I have, but I downloaded it via the phpVMS link, which is from Github I think, so I assume it's the latest version.

I'm no expert at the php language, although over this last week I've improved :-), but I had a go at your suggestion.

I had a look to see if the entry was already there, but it wasn't, so I added what you said I should (copied and pasted).  I wasn't sure where to add it, so placed it at the very bottom of the page.

Unfortunately, it hasn't made any difference, I'm still getting the same error,

Once again, thanks for the help.  I'd be lost without it.  Any further suggestions/advice would be appreciated.

Edited by peterc
Link to comment
Share on other sites

OK Done, it Yeh !!!!!!!

For anybody else who has the same problem in the future this is how I did it:

1) Go to uploaded phpVMS files on your host server

2) Find public_html/Core/local.config.php

3) Back up the local.config.php (just in case)

4) Under the 'Page encoding' entry insert:

#PHPVMS Server
Config::Set('PHPVMS_API_SERVER', 'http://api.vacentral.net');

5) Save

Thanks to Servetas for pointing me in the right direction and for passing on the info.  Another little bit of php mystery revealed :-)

 

Edited by peterc
Link to comment
Share on other sites

Make sure you have this version of phpvms (it's not required, but it will help for it being the most stable version).

Then check that your local.config.php file has this in it (as I see you do), the lookup line isn't required by phpvms 5.5.x because it no longer uses geonames to pull data officially. Try removing the lookup server line as well and see if that makes a difference.

Config::Set('PHPVMS_API_SERVER', 'http://api.vacentral.net');

Then test to see if the airport isn't making any trouble by going to here http://api.vacentral.net/index.php/airport/get/ and after the get/ put the icao and see if it returns data at the end of the page.

Like this http://api.vacentral.net/index.php/airport/get/KLAX returns this

({"totalResultsCount":1,"airports":[{"icao":"KLAX","name":"Los Angeles International Airport","countryName":"United States","lat":"33.9425","lng":"-118.408","lowlead":"0","jeta":"0"}]})

After that, reload the add airport page and open up the browser console and see if any errors appear after you click the fetch airport data button (then it will be a javascript error).

See if any of this works.

Link to comment
Share on other sites

  • 4 weeks later...
  • Administrators
2 hours ago, elmoussati said:

Yes, ofc it will not, because the source website is down, check that link page with errors http://api.vacentral.net/index.php/airport/get/OERK
 

If you scroll to the bottom of the page, after the error boxes, you should see:

({"totalResultsCount":1,"airports":[{"icao":"OERK","name":"King Khaled International Airport","countryName":"Saudi Arabia","lat":"24.9576","lng":"46.6988","lowlead":"0","jeta":"0"}]})

Link to comment
Share on other sites

On 2/19/2017 at 3:18 AM, ProAvia said:

If you scroll to the bottom of the page, after the error boxes, you should see:

({"totalResultsCount":1,"airports":[{"icao":"OERK","name":"King Khaled International Airport","countryName":"Saudi Arabia","lat":"24.9576","lng":"46.6988","lowlead":"0","jeta":"0"}]})

Hi sir,

I saw it before, but doesn't matter for me, since the feature isn't workable from my website, i can gather like those info from other resources.

Yours,

Link to comment
Share on other sites

  • 2 years later...
  • Administrators
14 minutes ago, nicky9499 said:

Bump. This is still broken as of 1/1/2020.

And it will remain so until after vaCentral is back on line. Additionally, it will require several coding changes as the API and provided info will change.

There are several online resources to look the required data up manually.

Link to comment
Share on other sites

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...