Q: I have installed the UNIX version of the Apache module by step, but my php script source is displayed in the browser, or the browser prompts me to save the file. Why?
A: This is because the PHP module is not working properly. Please check the following three places:
Make sure that the Apache execution file you are running is the one you succeeded in compiling the final compilation. Enter the following command:
/path/to/binary/httpd-l
If you don't see mod_php3.c in the list, then you don't run a correct execution file.
Make sure you have added the correct Mime Type in one of your. conf. This should look like this:
AddType application/x-httpd-php3. php3
Make sure the "AddType" above is not in or out of the block, otherwise this addtype will only take effect in the current VirtualHost or directory.
Two
Q: I have followed the instructions to install PHP, but my PHP still can't work with IIS, why?
A: You must make sure that the user running PHP has sufficient privileges to run Php.exe. The IIS server uses an anonymous account that is created at installation time, and this account needs to run Php.exe permissions. In addition, any user who has to be proven has the right to run Php.exe.
Three
Q: How do I compile php with Apache 1.3.X?
A: This is simple, just follow the steps below:
-Get the latest Apache distribution from the Apache site
-Unzip/untar files to a directory, such as/usr/local/src/apache-1.3.9
-Enter "./configure--with-apache=/path/to/your/apache" to start compiling PHP for the first time
-Execute "make" sequentially, "make install", create and copy the necessary files into the Apache directory
-Enter the Apache directory to edit the configuration file. At the end of the file, add: "Addmodule modules/php3/libphp3.a"
Execute "./configure", "make"
All done, you've got an Apache executable file that runs PHP.
Four
Q: When I compile PHP and Apache together, there seems to be a problem. It always says that the Httpd.h file cannot be found, but in fact the file exists. Why?
A: You need to let the PHP configuration/installation script know your Apache source's top-level directory, not the directory containing the Httpd.h file. In other words, you should specify "--with-apache=/path/to/apache/" instead of "--with-apache=/path/to/apache/src".
Five
Q: I installed PHP using RPM, but Apache can't process php files. Why?
A: Assuming you use RPM to properly install PHP, you must either reverse or add the following lines to the httpd.conf file:
To the global part of httpd.conf, or to the section where you need to provide PHP support.
Six
Q: How do I send mail using the Mail function under Windows?
A: PHP in Unix/linux sent mail with the SendMail program, in Windows without SendMail, but you can use the SMTP protocol to complete, as follows: Modify the php.ini file under the [Mail function] SMTP.
Such as:
[Mail Function]
smtp=public.sta.net.cn; Win32 only
Seven
Ask:p Hp+apache the setting under Win9x
Runtime appears: "Cannot determine local host name,use servername to set it manually"
If you have an IP address, simply add it to the httpd.conf:
ServerName http://your IP
For example: ServerName http://162.105.38.100
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.