Page 1 of 1

PHPWebAdmin does not work after update.

Posted: 2016-07-16 04:09
by ttomaras

I performed an upgrade from version 1950 to 2367. All went well. Emails are reachable from Outlook and I can receive/send to my Gmail account without a problem. I can't make PHPWebAdmin to work though. I copied the files contained in the Program Folder of hmailserver to the directory of PHPWebAdmin, I edited the config file and when I tried to test the interface the following message comes up.
Operation failed

The operation failed. Please make sure that you have logged on with the appropriate permissions to perform this task.

The following description exists:

htmlspecialchars() expects at most 3 parameters, 4 given

Error location: functions.php
Please note that I am using PHP 5.2.0.

Thank you.

Re: PHPWebAdmin does not work after update.

Posted: 2016-07-16 08:26
by jimimaseye

Re: PHPWebAdmin does not work after update.

Posted: 2016-07-16 11:15
by ttomaras
Yes I did.
It used to work just fine with the previous version and I suppose I did everything right this time.

Please note that I am not that familiar with the world of PHP.

Re: PHPWebAdmin does not work after update.

Posted: 2016-07-16 14:00
by percepts
your verson of PHP was released in Nov 2006. It is 10 Years old which is an eternity in web terms!!!.

The htmlspecialchars function had its 4th parameter(double encode) added in PHP version 5.2.3 Released: 31 May 2007 (9 years ago).

I have no idea what changes have been made in the PHPWebAdmin code over the years but htmlspecialchars is being used by quite a few other functions in the code and is always being called with 4th parameter set to true (the default). Its probably been in the hmail php code for a very long time too.

With PHP it pays to keep your PHP version, code and scripts upto date otherwise you get trapped in the past and can't use newer scripts.

If you upgrade PHP to current version some of your other old PHP scripts may stop working and would require modifying to correct for altered or removed PHP functions. So you are caught between a rock and a hard place.

Only you can know whether you have much old code that would fail if you upgrade PHP and that is a PHP programming maintenance role that you should be performing yourself if you are running PHP. Its no good claiming you don't know PHP if you are using PHP. You'll need to hire someone to sort it out for you or go back to your old version of hmail.

Re: PHPWebAdmin does not work after update.

Posted: 2016-07-16 14:24
by Dravion
Even in PHP 5 3 a lot of things had changed and nowdays PHP7 is out for quite a time.

Talk to your ISP or Server admin and tell him he should just upgrade your webspace.

Or just type in:
sudo apt-get upgrade -y (for Debian based Linux)
sudo yum upgrade -y (for Redhat based Linux)

Or if you on Windows load a supported mainstream PHP
zip package (threadsafe one for Apache2) or the non-threadsafe for IIS and NGINX
Webservers on Windows.Adjust php.ini to your need and you are ready to go.