Re: PHP7

"Janky Jay, III" <[email protected]>
Newsgroups gmane.mail.virus.maiamailguard
Message-ID <[email protected]>
Hello PJ,

On 9/15/18 2:42 PM, [email protected] wrote:

Thanks for the reply.
> The problem seems to be in your stack trace:
>
> 	PHP Fatal error:  Uncaught Error: Call to undefined method ThemeSmarty::addPluginsDir()
>
> I don't know the specifics of this error, but here are the general issues I typically run into when moving a code base like Maia to a new/updated platform:
>
>  - Updated dependencies are not backwards compatible (from the error, it looks like the problem is related to "Smarty", a PHP library for processing templates - see https://www.smarty.net/docs/en/api.add.plugins.dir.tpl for ideas)
    Smarty is definitely installed and the proper links are in place.
>  - Missing dependences, either because they haven't been installed or haven't been added to appropriate include path(s)
    The Smarty path is included in the allowed path for that particular
(sub)domain. Everything looks good from the Apache side.

>  - PHP Backwards compatibility issues (some part of the core PHP is not backwards compatible)
>
> In the case of Smarty, it could be that it hasn't been installed, it is installed, but not on the include path or that the new version is not backwards compatible with the version used for Maia. If the issue is backwards compatibility, you can either try to fix the Maia code or you could try to install an older version (which may or may not be possible, depending on its dependency tree).
>
> PHP is interpreted rather than complied, so, after you get this error fixed, that may reveal new errors.
    I guess I already mentioned it above but just to be thorough,
Smarty2 is installed (perhaps the latest version of Maia depends on
Smarty3?). The Smarty path is indeed in the include_path for the domain.
If I downgrade a previous version of PHP (php56), Maia works without any
issues. So, perhaps this is a PHP backward compat problem. I thought for
sure I had read that some people were using Maia with PHP7 with very
little to no issues, though. The actual daemon itself runs fine (of
course...) so it's still doing it's job, technically. There's just no
way to use the WebUI to confirm/rescue SPAM and such.

>
> PJ
>
> -----Original Message-----
> From: Maia-users <[email protected]> On Behalf Of Janky Jay, III
> Sent: Saturday, September 15, 2018 9:57 AM
> To: [email protected]
> Subject: Re: [Maia-users] PHP7
>
> So, I'm shooting to get the Maia port updated for FreeBSD in order to work with PHP7 (as almost all PHP applications have migrated to). The install goes fine, configtest.pl/configtest.php both look good.
> Everything installs as expected and looks good after a few minor changes to the port. However, I'm getting a blank login page which I haven't been able to figure out (yet) and was curious if anyone else has run into this yet (forgive me if this has already been covered but I couldn't find any info on the mailing lists or Github page...). Below is  snippet from the log which has some warnings and finally the fatal error. Any help would be greatly appreciated!
>
> If the below doesn't come out very readable, it can also be found at http://paste.purplehat.org/view/26532b5f
>
> [Sat Sep 15 10:54:10.922180 2018] [php7:notice] [pid 91494] [client 172.28.35.18:20952] PHP Notice:  Only variables should be assigned by reference in /usr/local/www/maia/maia_log.php on line 87 [Sat Sep 15 10:54:10.922389 2018] [php7:notice] [pid 91494] [client 172.28.35.18:20952] PHP Notice:  Only variables should be assigned by reference in /usr/local/www/maia/maia_log.php on line 92 [Sat Sep 15 10:54:11.019177 2018] [php7:notice] [pid 91494] [client 172.28.35.18:20952] PHP Notice:  Only variables should be assigned by reference in /usr/local/www/maia/maia_log.php on line 87 [Sat Sep 15 10:54:11.019308 2018] [php7:notice] [pid 91494] [client 172.28.35.18:20952] PHP Notice:  Only variables should be assigned by reference in /usr/local/www/maia/maia_log.php on line 92 [Sat Sep 15 10:54:11.019874 2018] [php7:warn] [pid 91494] [client 172.28.35.18:20952] PHP Warning:  count(): Parameter must be an array or an object that implements Countable in /usr/local/share/pear/MDB2.php on line 826 [Sat Sep 15 10:54:11.021245 2018] [php7:notice] [pid 91494] [client 172.28.35.18:20952] PHP Notice:  A non well formed numeric value encountered in /usr/local/share/pear/MDB2/Driver/mysqli.php on line 1154 [Sat Sep 15 10:54:11.079592 2018] [php7:notice] [pid 91494] [client 172.28.35.18:20952] PHP Notice:  A non well formed numeric value encountered in /usr/local/share/pear/MDB2/Driver/mysqli.php on line 1154 [Sat Sep 15 10:54:11.102862 2018] [php7:notice] [pid 91494] [client 172.28.35.18:20952] PHP Notice:  A non well formed numeric value encountered in /usr/local/share/pear/MDB2/Driver/mysqli.php on line 1154 [Sat Sep 15 10:54:11.103505 2018] [php7:notice] [pid 91494] [client 172.28.35.18:20952] PHP Notice:  A non well formed numeric value encountered in /usr/local/share/pear/MDB2/Driver/mysqli.php on line 1154 [Sat Sep 15 10:54:11.103983 2018] [php7:notice] [pid 91494] [client 172.28.35.18:20952] PHP Notice:  A non well formed numeric value encountered in /usr/local/share/pear/MDB2/Driver/mysqli.php on line 1154 [Sat Sep 15 10:54:11.104440 2018] [php7:notice] [pid 91494] [client 172.28.35.18:20952] PHP Notice:  A non well formed numeric value encountered in /usr/local/share/pear/MDB2/Driver/mysqli.php on line 1154 [Sat Sep 15 10:54:11.104933 2018] [php7:notice] [pid 91494] [client 172.28.35.18:20952] PHP Notice:  A non well formed numeric value encountered in /usr/local/share/pear/MDB2/Driver/mysqli.php on line 1154 [Sat Sep 15 10:54:11.120424 2018] [php7:notice] [pid 91494] [client 172.28.35.18:20952] PHP Notice:  A non well formed numeric value encountered in /usr/local/share/pear/MDB2/Driver/mysqli.php on line 1154 [Sat Sep 15 10:54:11.120929 2018] [php7:notice] [pid 91494] [client 172.28.35.18:20952] PHP Notice:  A non well formed numeric value encountered in /usr/local/share/pear/MDB2/Driver/mysqli.php on line 1154 [Sat Sep 15 10:54:11.133056 2018] [php7:error] [pid 91494] [client 172.28.35.18:20952] PHP Fatal error:  Uncaught Error: Call to undefined method ThemeSmarty::addPluginsDir() in /usr/local/www/maia/smarty.php:99\nStack trace:\n#0
> /usr/local/www/maia/smarty.php(189):
> ThemeSmarty->ThemeSmarty('desert_sand')\n#1
> /usr/local/www/maia/login.php(122):
> require_once('/usr/local/www/...')\n#2 {main}\n  thrown in /usr/local/www/maia/smarty.php on line 99
>
> On 11/30/17 7:56 AM, Derek Atkins wrote:
>> "Ian R. Justman" <ianj-/[email protected]> writes:
>>
>>> And as far as I know, the PHP side of the house has yet to be updated 
>>> to support PHP7.  Given what little I know of PHP in general (and how 
>>> much the whole notion of PHP scares me when it comes to security*1, 
>>> I'm scared to death of even thinking of trying.
>> I've been led to believe (although I have not yet tested it) that maia 
>> does support PHP7.  There were certainly some updates to the config 
>> tester for PHP7.
>>
>> I'm in the process of testing (on a Fedora system) so I'll let you all 
>> know what I find once I get that far.
>>
>> -derek
>
>

_______________________________________________
Maia-users mailing list
[email protected]
http://www.renaissoft.com/cgi-bin/mailman/listinfo/maia-users
signature.asc (application/pgp-signature, 195 B)
-----BEGIN PGP SIGNATURE-----

iF0EARECAB0WIQT3labtx1DPvRcqv5cYrcyxRslmfgUCW6GRRAAKCRAYrcyxRslm
fgWWAJ9dAKTfetRZZPlQ1N6TN75jcNHQSwCfaMmui+74mUiSZi0nUsp1Psk+aHo=
=QPH5
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.