Install PHP 5
From OpenFSG
| Please help improve this article by expanding it.
Further information might be found on the talk page. |
|
This article describes how to install PHP 5 for Apache 2.
Prerequisits
You should have read and understood:
Installing
ipkg update ipkg install php-apache
Add PHP support to apache config:
Add the line "Inlcude /opt/etc/apache2/conf.d/php.conf" to file /opt/etc/apache2/httpd.conf
Restart apache server
killall httpd /etc/init.d/http start /opt/etc/init.d/S80apache
Further Informations
- Autostart problems of Apache during boot process: Use the Custom Ipkg Installer
Fixes
- GZOPEN problem
I wanted to keep my original apache 1.3 located in /usr/local/apache to keep the admintools of my datatank as is. Therefor I added the following line to the "start" option of /etc/init.d/http script. (Yes I'm running 2 apaches side by side on different ports).
... echo "Starting APACHE 2 ..." /opt/sbin/httpd ...
When I restarted the daemons I got the following error message: (note linenumbers may differ)
httpd: Syntax error on line 480 of /opt/etc/apache2/httpd.conf: Syntax error on line 6 of /opt/etc/apache2/conf.d/php.conf: Cannot load /opt/libexec/libphp5.so into server: /opt/lib/libxml2.so.2: undefined symbol: gzopen64
Fixed this gzopen64-error by updating zlib to version 1.2.5
ipkg install zlib