VSG24 VSG24 - 5 years ago 321
PHP Question

All php functions work but phpinfo

I recently upgraded my VPS PHP version to 7.0.3 and everything seems to work fine including

php -v
which shows:

(I know I'm getting some warnings but those shouldn't be anything serious)

Failed loading /usr/local/lib/ioncube/ioncube_loader_lin_5.3.so: /usr/local/lib/ioncube/ioncube_loader_lin_5.3.so: undefined symbol: execute
PHP Warning: PHP Startup: suhosin: Unable to initialize module
Module compiled with module API=20090626
PHP compiled with module API=20151012
These options need to match
in Unknown on line 0
PHP 7.0.3 (cli) (built: Feb 14 2016 00:24:25) ( NTS )
Copyright (c) 1997-2016 The PHP Group
Zend Engine v3.0.0, Copyright (c) 1998-2016 Zend Technologies


I'm using directadmin and so I created a file
index.php
in the
public_html
and this is its content:

<?php
error_reporting(E_ALL);

echo md5("sometext");

phpinfo();

?>


The output is only:

a29e90948f4eee52168fab5fa9cfbcf8


Why are
md5
and
echo
working but not
phpinfo
???

I'm on Centos and using PHP 7.0.3 with Apache (httpd) 2.4.9

Answer Source

phpinfo() is disabled for free accounts on that particular hosting provider
if youhave access to php.ini
Go to the php.ini and remove phpinfo from

disable_functions =...,phpinfo,....

save and restart webserver

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download