Jump to content

Installation - PHAR extension check

1 reply to this topic

#1 Funnyman


  • Members
  • PipPip
  • 18 posts

Posted 11 October 2018 - 02:20 PM

I've discovered a small "bug" on the index page where LiveZilla checks the system configuration.

The check for the availability of the PHAR extension seems to be a bit complicated. I have a system where PHAR support is definitely available through the PHAR extension, but the index page shows a warning, that the extension is missing. After a short research, I found the check for the extension in "/_lib/functions.index.inc.php" on line 115. The check is done by searching for "--disable-phar" string in the output of the phpinfo() function. This leads to the problem. Many systems have the "--disable-phar" string in their phpinfo() output, but they use the extension for PHAR support.

My suggestion is to check for the existance of the class 'Phar' to check, if PHAR support is available.

115 : if (!class_exists('Phar'))
116 :	 $message .= "<span>Missing PHP extension: PHAR<br></span> <span>LiveZilla requires the PHP extension PHAR to be installed and enabled. Please add the PHAR extension to your PHP configuration (php.ini).</span><br><br>";

#2 Patrick Keil


  • Administrators
  • 3792 posts
  • LocationSingen, Germany

Posted 11 October 2018 - 02:45 PM


Thanks for that!

Your approach might be more reliable, we will run some tests tomorrow.


1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users