Jump to content

frontpage_main errors after Host Move


SupernovaSurfer

Recommended Posts

We recently moved our Database over to new Hosting and also upgraded to PHPvms 5.5.2 / Php version 5.6 / Paid Hosting.

After the move the frontpage on the site throws quite a few errors. At the outset I have to thank Eddie Baker and Vangelis for their help so far.

A couple of the errors are :

  • Warning: Invalid argument supplied for foreach() in /home/airin9ce/public_html/vms2/lib/skins/etc/frontpage_recentpilots.php on line 7

In the mail to admin on pirep submission :

  • A PIREP has been submitted by 0000 ( ) AI202: OKBK to OMSJ Aircraft: 60 Flight Time: 01.39 Landing Rate: -256 Filed using: smartCARS Comment: Click to approve this pirep (admin must be signed in):

From the PIREPdata class:

  • # Send an email to the admin that a PIREP was submitted
  •             $sub = "A PIREP has been submitted by {$pilotcode} ({$pirepdata['depicao']} - {$pirepdata['arricao']})";
  •             $message = "A PIREP has been submitted by {$pilotcode} "

The main issues are on the frontpage with Recent Reports / New pilots / and Recent Flights return blank from the maincontroller run functions I guess because of the IF( ! $XXX) functions in the class ?

Would be great if anyone can help with this.  Website : http://www.airindiavirtual.net

Deepan

Edited by airindia1
Link to comment
Share on other sites

  • Moderators

Some variables have changed between the two versions. Your template seems to call some deprecated variables. What does line 7 of your /home/airin9ce/public_html/vms2/lib/skins/etc/frontpage_recentpilots.php  have? Maybe it looks like this:

foreach($pilot_list as $pilot) {

Also, in your core/common/PIREPData.class.php file, what do lines 750-755 have?

Link to comment
Share on other sites

Servetas thanks for the reply

Yes I did try changing the variables $pilots for $pilots list / $pirep_list and $pireps for the recent reports .

  • frontpage_recentpilots does  show  foreach($pilot_list as $pilot)

Line 750-755 has

# Update any pilot's information
        $pilotinfo = PilotData::getPilotData($pirepdata['pilotid']);
        $pilotcode = PilotData::getPilotCode($pilotinfo->code, $pilotinfo->pilotid);
        PilotData::UpdateLastPIREPDate($pilotinfo->pilotid);
        PirepAcData::search($pirepid);
        if (Config::Get('EMAIL_SEND_PIREP') === true

 

Deepan

Link to comment
Share on other sites

  • Moderators
On 7/19/2017 at 0:06 PM, airindia1 said:

Servetas thanks for the reply

Yes I did try changing the variables $pilots for $pilots list / $pirep_list and $pireps for the recent reports .

  • frontpage_recentpilots does  show  foreach($pilot_list as $pilot)

Line 750-755 has

# Update any pilot's information
        $pilotinfo = PilotData::getPilotData($pirepdata['pilotid']);
        $pilotcode = PilotData::getPilotCode($pilotinfo->code, $pilotinfo->pilotid);
        PilotData::UpdateLastPIREPDate($pilotinfo->pilotid);
        PirepAcData::search($pirepid);
        if (Config::Get('EMAIL_SEND_PIREP') === true

 

Deepan

In your cpanel, change your php version on your domain to 5.4 if available and see if you get the same errors. You could try php 5.5 as well. You would look for "MultiPHP Manager" section in cpanel.

Link to comment
Share on other sites

  • 2 weeks later...

Also for what its worth...... the reset hours in Admin doesn't work for all pilots

Calculating hours for all pilots:
AI0001 - found 1 flight hours for number
AI0002 - found 1 flight hours for number
AI0003 - found 1 flight hours for number
AI0004 - found 1 flight hours for number
AI0006 - found 1 flight hours for number
AI0008 - found 1 flight hours for number
IX0010 - found 1 flight hours for number

Re-setting pirep count works fine

 

Deepan

 

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