- 论坛徽章:
- 0
|
环境: RHEL3U5, APACHE2.0.55, PHP4.4.2
1-编译安装APACHE -> /usr/local/httpd
./configure --exec-prefix=/usr/local/httpd --prefix=/usr/local/httpd --enable-so
make
make install
2-编译安装PHP -> /usr/local/httpd/php
./configure --prefix=/usr/local/httpd/php --with-config-file-path=/usr/local/httpd/php --enable-sockets --with-mysql=/usr/local/mysql --with-zlib-dir=/usr/include --with-gd
make
make install
3-配置
cp php.ini-dist /usr/local/httpd/php/php.ini
vi /usr/local/httpd/conf/httpd.conf
# add the follwing lines
AddType application/x-tar .tgz
AddType application/x-httpd-php .php
AddType image/x-icon .ico
DirectoryIndex index.php index.html index.html.var
4-测试
more /usr/local/httpd/htdocs/index.php
<html>
<p>If PHP is working, you will see "Hello World" below:<hr>
<?php
echo "Hello world";
phpinfo(); // Print PHP version and config info
?>
</html>
IE 6中输入 http://linux_ip/index.php,却提示下载index.php文件!!!
哪位老大,给说一下原因和怎么解决??
谢谢!!! |
|