Jump to content

Web site update issue


reed0427

Recommended Posts

If I try to update the NEWS section of my website, I get this message:

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator at webmaster@historicairlinegroup.com to inform them of the time this error occurred, and the actions you performed just before this error.

More information about this error may be available in the server error log.

Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.

 

Any ideas?

 

David Reed/Historic Airline Group

Link to comment
Share on other sites

  • Administrators

Are you updating the module or just adding new news?

If updating the module, compare the old and new files to see what changed and if you really do need to update.

Did your host just upgrade your Apache, PHP or MySQL? I had my host upgrade PHP from 7.2.18 to a newer version and got the same error in phpVMS 7. They said it was the program and not them. Turns out the issue was a misconfigured PHP install - once they updated it again the issue was resolved. Folks using the same PHP version on a different host/server did not have the issue using the same program as me.

Edited by ProAvia
Link to comment
Share on other sites

  • Administrators

Does the error_log show any errors? I think you should have an error_log in the root of phpVMS and in the admin directory.

Are you still getting the Internal Server Error? And if so, only with the news module?

What version of phpVMS? Have you compared your installed news module with the news module of a default phpVMS download?

 

Link to comment
Share on other sites

  • Moderators
On 10/20/2019 at 2:43 PM, reed0427 said:

If I try to update the NEWS section of my website, I get this message:

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator at webmaster@historicairlinegroup.com to inform them of the time this error occurred, and the actions you performed just before this error.

More information about this error may be available in the server error log.

Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.

 

Any ideas?

 

David Reed/Historic Airline Group

Can I see your .htaccess?

sometimes this file throw this issue in web hostings.

Try to delete .htaccess (that you have uploaded with phpvms installation), maybe your web hosting provider bring any configuration of this file include.

Link to comment
Share on other sites

You mean this?

<?php
/**
 * phpVMS - Virtual Airline Administration Software
 * Copyright (c) 2008 Nabeel Shahzad
 * For more information, visit www.phpvms.net
 *    Forums: http://www.phpvms.net/forum
 *    Documentation: http://www.phpvms.net/docs
 *
 * phpVMS is licenced under the following license:
 *   Creative Commons Attribution Non-commercial Share Alike (by-nc-sa)
 *   View license.txt in the root, or visit http://creativecommons.org/licenses/by-nc-sa/3.0/
 *
 * @author Nabeel Shahzad
 * @copyright Copyright (c) 2008, Nabeel Shahzad
 * @link http://www.phpvms.net
 * @license http://creativecommons.org/licenses/by-nc-sa/3.0/
 */

class News extends CodonModule
{
    public function index()
    {
        $this->ShowNewsFront(5);
    }
    
    // This function gets called directly in the template
    public function ShowNewsFront($count=5)
    {
        $sql='SELECT id, subject, body, postedby, UNIX_TIMESTAMP(postdate) AS postdate
                FROM ' . TABLE_PREFIX .'news
                ORDER BY postdate DESC
                LIMIT '.$count;
        
        $res = DB::get_results($sql);
        
        if(!$res)
            return;
            
        foreach($res as $row)
        {
            //TODO: change the date format to a setting in panel
            $this->set('subject', $row->subject);
            $this->set('body', $row->body);
            $this->set('postedby', $row->postedby);
            $this->set('postdate', date(DATE_FORMAT, $row->postdate));
        
            $this->show('news_newsitem.tpl');
        }
    }
}

Link to comment
Share on other sites

  • Administrators

Are you using phpVMS version 2.1.x or 5.5.2 (Simpilot version)?

There are several files to compare.... 

  • /core/modules/news/news.php
  • /core/templates/news_newsitem.tpl - may end in .php instead of .tpl - this one may be in your active skin folder, which will take precedence over the one in /core/templates/
  • /admin/modules/SiteCMS/SiteCMS.php
  • /admin/templates/news_additem.php - may end in .tpl instead of .php
  • /admin/templates/news_list.php - may end in .tpl instead of .php
  • /core/common/SiteData.class.php
  • /core/common/LogData.class.php

Compare the above files on your site to the ones in a default install (or non-edited files from a download of your version of phpVMS).

Don't change the file names or extensions - just compare to default. Let us know what you find out.

 

Edited by ProAvia
Link to comment
Share on other sites

this is from the error log in the public_html/admin folder:

[24-Oct-2019 01:48:53 UTC] PHP Warning:  Invalid argument supplied for foreach() in /home/historic/public_html/admin/modules/PIREPAdmin/PIREPAdmin.php on line 130
[24-Oct-2019 01:48:59 UTC] PHP Warning:  Invalid argument supplied for foreach() in /home/historic/public_html/admin/modules/PIREPAdmin/PIREPAdmin.php on line 130

 

Of course, those are just from  recent

I'll PM you

Edited by reed0427
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...