I programmed a website, no need to get into more detail about it but it works and does not require any DB or something like that. But on my new Ubuntu 10.04.4 LTS Server all PHP pages show up blank. I have installed Apache2, PHP5 and something I don't know what it is for with the following commands:
我编写了一个网站,无需详细了解它,但它有效并且不需要任何数据库或类似的东西。但在我的新Ubuntu 10.04.4 LTS服务器上,所有PHP页面都显示为空白。我使用以下命令安装了Apache2,PHP5以及我不知道它的用途:
sudo apt-get install apache2
sudo apt-get install php5
sudo apt-get install libapache2-mod-php5
sudo /etc/init.d/apache2 restart
I have tried to deinstall and reinstall all of these components without and luck. None of the PHP pages show up in my browser, they show up blank and with a blank source, whereas all my pure .html pages work fine.
我试图卸载并重新安装所有这些组件没有和运气。我的浏览器中没有显示任何PHP页面,它们显示为空白且带有空白源,而所有纯.html页面都可以正常工作。
Is there any way to get it working, I would be happy to post more information but I do not know where I should get that.
有没有办法让它工作,我很乐意发布更多的信息,但我不知道我应该在哪里得到它。
Error Log:
PHP Deprecated: Comments starting with '#' are deprecated in /etc/php5/apache2/conf.d/mcrypt.ini on line 1 in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20090626/curl.so' - /usr/lib/php5/20090626/curl.so: cannot open shared object file: No such file or directory in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20090626/gd.so' - /usr/lib/php5/20090626/gd.so: cannot open shared object file: No such file or directory in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20090626/mcrypt.so' - /usr/lib/php5/20090626/mcrypt.so: cannot open shared object file: No such file or directory in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20090626/mysql.so' - /usr/lib/php5/20090626/mysql.so: cannot open shared object file: No such file or directory in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20090626/mysqli.so' - /usr/lib/php5/20090626/mysqli.so: cannot open shared object file: No such file or directory in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20090626/pdo_mysql.so' - /usr/lib/php5/20090626/pdo_mysql.so: cannot open shared object file: No such file or directory in Unknown on line 0
[Mon Jul 23 00:36:05 2012] [notice] Apache/2.2.14 (Ubuntu) PHP/5.3.2-1ubuntu4.15 with Suhosin-Patch configured -- resuming normal operations
[Mon Jul 23 00:36:16 2012] [error] [client 217.227.25.35] PHP Parse error: syntax error, unexpected ')' in /var/www/vtest5532/Header.php on line 19
[Mon Jul 23 00:36:17 2012] [error] [client 217.227.25.35] PHP Parse error: syntax error, unexpected ')' in /var/www/vtest5532/Header.php on line 19
[Mon Jul 23 00:38:09 2012] [notice] caught SIGTERM, shutting down
PHP Deprecated: Comments starting with '#' are deprecated in /etc/php5/apache2/conf.d/mcrypt.ini on line 1 in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20090626/curl.so' - /usr/lib/php5/20090626/curl.so: cannot open shared object file: No such file or directory in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20090626/gd.so' - /usr/lib/php5/20090626/gd.so: cannot open shared object file: No such file or directory in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20090626/mcrypt.so' - /usr/lib/php5/20090626/mcrypt.so: cannot open shared object file: No such file or directory in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20090626/mysql.so' - /usr/lib/php5/20090626/mysql.so: cannot open shared object file: No such file or directory in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20090626/mysqli.so' - /usr/lib/php5/20090626/mysqli.so: cannot open shared object file: No such file or directory in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20090626/pdo_mysql.so' - /usr/lib/php5/20090626/pdo_mysql.so: cannot open shared object file: No such file or directory in Unknown on line 0
[Mon Jul 23 00:38:10 2012] [notice] Apache/2.2.14 (Ubuntu) PHP/5.3.2-1ubuntu4.15 with Suhosin-Patch configured -- resuming normal operations
[Mon Jul 23 00:38:59 2012] [error] [client 180.76.5.62] File does not exist: /var/www/Forum
[Mon Jul 23 01:10:36 2012] [error] [client 66.249.68.165] File does not exist: /var/www/Forum
[Mon Jul 23 01:10:36 2012] [error] [client 66.249.68.165] File does not exist: /var/www/Forum
1 个解决方案
#1
0
PHP is configured not to display errors by default. If you check the Apache error log at /var/log/apache2/error.log
you should see the cause of the problem. If this is a development machine you should also change your php.ini
file to a more dev-friendly setup (show errors, error_reporting
at max). If it's a production server then leave the php.ini as-is.
PHP配置为默认不显示错误。如果您检查/var/log/apache2/error.log上的Apache错误日志,您应该看到问题的原因。如果这是一台开发机器,您还应该将php.ini文件更改为更友好的设置(显示错误,最大错误报告)。如果它是生产服务器,那么保持原样的php.ini。
#1
0
PHP is configured not to display errors by default. If you check the Apache error log at /var/log/apache2/error.log
you should see the cause of the problem. If this is a development machine you should also change your php.ini
file to a more dev-friendly setup (show errors, error_reporting
at max). If it's a production server then leave the php.ini as-is.
PHP配置为默认不显示错误。如果您检查/var/log/apache2/error.log上的Apache错误日志,您应该看到问题的原因。如果这是一台开发机器,您还应该将php.ini文件更改为更友好的设置(显示错误,最大错误报告)。如果它是生产服务器,那么保持原样的php.ini。