cvs: phpdoc / faqurls.ent /en/faq installation.xml

From: Date: Sun, 14 Oct 2001 09:16:30 +0000
Subject: cvs: phpdoc / faqurls.ent /en/faq installation.xml
Groups: php.doc 
Request: Send a blank email to phpdoc+get-969337968@lists.php.net to get a copy of this message
goba Sun Oct 14 05:16:30 2001 EDT Modified files: /phpdoc faqurls.ent /phpdoc/en/faq installation.xml Log: Adding questions and answers from php4/win32/install.txt

Index: phpdoc/faqurls.ent diff -u phpdoc/faqurls.ent:1.13 phpdoc/faqurls.ent:1.14 --- phpdoc/faqurls.ent:1.13 Mon Oct 8 11:25:26 2001 +++ phpdoc/faqurls.ent Sun Oct 14 05:16:30 2001 @@ -1,6 +1,6 @@ <!-- -*- SGML -*- - $Id: faqurls.ent,v 1.13 2001/10/08 15:25:26 mj Exp $ + $Id: faqurls.ent,v 1.14 2001/10/14 09:16:30 goba Exp $ Contains "macros" for all the XML documents within the FAQ. @@ -23,7 +23,6 @@ <!ENTITY faqurl.halcyon "http://www.halcyonsoft.com/"> <!ENTITY faqurl.iis "http://support.microsoft.com/support/kb/articles/q160/4/22.asp"> <!ENTITY faqurl.imap "ftp://ftp.cac.washington.edu/imap/old/imap-4.5.tar.Z"> -<!ENTITY faqurl.install "http://benoit.noss.free.fr/php/install-php4.html"> <!ENTITY faqurl.instantasp "http://www.halcyonsoft.com/prods/iasp/iasp.htm"> <!ENTITY faqurl.ldap "ftp://ftp.openldap.org/pub/openldap/openldap-stable.tgz"> <!ENTITY faqurl.ldap.free "ftp://ftp.critical-angle.com/pub/cai/slapd/"> Index: phpdoc/en/faq/installation.xml diff -u phpdoc/en/faq/installation.xml:1.7 phpdoc/en/faq/installation.xml:1.8 --- phpdoc/en/faq/installation.xml:1.7 Thu Oct 4 17:10:04 2001 +++ phpdoc/en/faq/installation.xml Sun Oct 14 05:16:30 2001 @@ -1,32 +1,28 @@ <?xml encoding="iso-8859-1"?> -<!-- $Revision: 1.7 $ --> +<!-- $Revision: 1.8 $ --> <chapter id="faq.installation"> <title>Installation</title> <titleabbrev>Installation</titleabbrev> - <para> - This section holds common questions about the way to install - PHP. PHP is available for almost any OS (except may be for - MacOS before OSX), and almost any web server. - </para> - <para> - To install PHP, follow the instructions in the - <ulink url="&faqurl.file.installation;">INSTALL</ulink> - file located in the distribution. Windows 95 and NT users should also read the - <ulink url="&faqurl.file.readmewin;">install.txt</ulink> - file. There are also some helpful hints for Windows users - <link linkend="install.windows">here</link>. - </para> - <para> - If you are trying to install PHP for use with Netscape's web server on - Unix see: <ulink url="&faqurl.install;">&faqurl.install;</ulink> - </para> + <para> + This section holds common questions about the way to install + PHP. PHP is available for almost any OS (except maybe for + MacOS before OSX), and almost any web server. + </para> + <para> + To install PHP, follow the instructions in the + <ulink url="&faqurl.file.installation;">INSTALL</ulink> + file located in the distribution. Windows users should also read the + <ulink url="&faqurl.file.readmewin;">install.txt</ulink> + file. There are also some helpful hints for Windows users + <link linkend="install.windows">here</link>. + </para> <qandaset> <qandaentry id="faq.installation.phpini"> <question> <para> - Where should my php.ini file be located? + Unix/Windows: Where should my php.ini file be located? </para> </question> <answer> @@ -34,13 +30,17 @@ By default on UNIX it should be in <filename>/usr/local/lib</filename>. Most people will want to change this at compile-time with the <link linkend="install.configure.with-config-file-path">--with-config-file-path</link> - flag. You would, for example, set it to something like: - <programlisting> - --with-config-file-path=/etc - </programlisting> - And then you would copy <filename>php.ini-dist</filename> from - the distribution to <filename>/etc/php.ini</filename> and - edit it to make any local changes you want. + flag. You would, for example, set it with something like: + <programlisting> +--with-config-file-path=/etc + </programlisting> + And then you would copy <filename>php.ini-dist</filename> from + the distribution to <filename>/etc/php.ini</filename> and + edit it to make any local changes you want. + </para> + <para> + On Windows the default path for the <filename>php.ini</filename> + file is the Windows directory. </para> </answer> </qandaentry> @@ -48,7 +48,7 @@ <qandaentry id="faq.installation.processing"> <question> <para> - I installed PHP using RPMS, but Apache isn't processing the + Unix: I installed PHP using RPMS, but Apache isn't processing the PHP pages! What's going on here? </para> </question> @@ -56,7 +56,7 @@ <para> Assuming you installed both Apache and PHP from RPM packages, you need to uncomment or add some or all of the following lines - in your http.conf file: + in your <filename>http.conf</filename> file: <programlisting> # Extra Modules AddModule mod_php.c @@ -83,59 +83,59 @@ <qandaentry id="faq.installation.compile"> <question> <para> - I installed PHP using RPMS, but it doesn't compile with the database - support I need! What's going on here? + Unix: I installed PHP 3 using RPMS, but it doesn't compile with + the database support I need! What's going on here? </para> </question> <answer> <para> - Due to the way PHP is currently built, it is not easy to build a - complete flexible PHP RPM. This issue will be addressed in PHP 4. - For PHP, we currently suggest you use the mechanism described in the + Due to the way PHP 3 built, it is not easy to build a + complete flexible PHP RPM. This issue is addressed in PHP 4. + For PHP 3, we currently suggest you use the mechanism described in the INSTALL.REDHAT file in the PHP distribution. If you insist on using - an RPM version of PHP, read on... - </para> - <para> - Currently the RPM packagers are setting up the RPMS to install + an RPM version of PHP 3, read on... + </para> + <para> + The RPM packagers are setting up the RPMS to install without database support to simplify installations <emphasis>and</emphasis> because RPMS use /usr/ instead of the standard /usr/local/ directory for - files. You need to tell the RPM spec file which databases to support + files. You need to tell the RPM spec file which databases to support and the location of the top-level of your database server. - </para> - <para> + </para> + <para> This example will explain the process of adding support for the popular MySQL database server, using the mod installation for Apache. - </para> - <para> + </para> + <para> Of course all of this information can be adjusted for any database - server that PHP supports. We will assume you installed MySQL and Apache + server that PHP supports. We will assume you installed MySQL and Apache completely with RPMS for this example as well. <itemizedlist> - <listitem> - <para> - First remove mod_php3 : - <programlisting> + <listitem> + <para> + First remove mod_php3 : + <programlisting> rpm -e mod_php3 - </programlisting> - </para> - </listitem> - <listitem> - <para> - Then get the source rpm and INSTALL it, NOT --rebuild - <programlisting> + </programlisting> + </para> + </listitem> + <listitem> + <para> + Then get the source rpm and INSTALL it, NOT --rebuild + <programlisting> rpm -Uvh mod_php3-3.0.5-2.src.rpm - </programlisting> - </para> - </listitem> - <listitem> - <para> - Then edit the <filename>/usr/src/redhat/SPECS/mod_php3.spec</filename> file - </para> - <para> - In the %build section add the database support you want, and the path. - </para> - <para> - For MySQL you would add + </programlisting> + </para> + </listitem> + <listitem> + <para> + Then edit the <filename>/usr/src/redhat/SPECS/mod_php3.spec</filename> file + </para> + <para> + In the %build section add the database support you want, and the path. + </para> + <para> + For MySQL you would add <programlisting> --with-mysql=/usr \ </programlisting> @@ -150,30 +150,131 @@ --with-mysql=/usr \ --with-system-regex </programlisting> - </para> - </listitem> - <listitem> - <para> - Once this modification is made then build the binary rpm as follows: + </para> + </listitem> + <listitem> + <para> + Once this modification is made then build the binary rpm as follows: <programlisting> rpm -bb /usr/src/redhat/SPECS/mod_php3.spec - </programlisting> - </para> - </listitem> - <listitem> - <para> - Then install the rpm + </programlisting> + </para> + </listitem> + <listitem> + <para> + Then install the rpm <programlisting> rpm -ivh /usr/src/redhat/RPMS/i386/mod_php3-3.0.5-2.i386.rpm - </programlisting> - </para> - </listitem> + </programlisting> + </para> + </listitem> + </itemizedlist> + Make sure you restart Apache, and you now have PHP 3 with MySQL support + using RPM's. Note that it is probably much easier to just build + from the distribution tarball of PHP 3 and follow the instructions in + <filename>INSTALL.REDHAT</filename> found in that distribution. + </para> + </answer> + </qandaentry> + + <qandaentry id="faq.installation.blankscreen"> + <question> + <para> + Unix/Windows: I have installed PHP, but when I try to + access a PHP script file via my browser, I get a blank screen. + </para> + </question> + <answer> + <para> + Do a 'view source' in the web browser and you will probably + find that you can see the source code of your PHP script. + This means that the web server did not send the script to + PHP for interpretation. Something is wrong with the server + configuration - double check the server configuration against + the PHP installation instructions. + </para> + </answer> + </qandaentry> + + <qandaentry id="faq.installation.500error"> + <question> + <para> + Unix/Windows: I have installed PHP, but when try to + access a PHP script file via my browser, I get a + server 500 error. + </para> + </question> + <answer> + <para> + Something went wrong when the server tried to run PHP. To + get to see a sensible error message, from the command line, + change to the directory containing the PHP executable + (<filename>php.exe</filename> on Windows) and run + <literal>php -i</literal>. If PHP has any problems running, + then a suitable error message will be displayed which will + give you a clue as to what needs to be done next. If you + get a screen full of html codes (the output of the + <function>phpinfo</function> function) then PHP is working, + and your problem may be related to your server configuration + which you should double check. + </para> + </answer> + </qandaentry> + + <qandaentry id="faq.installation.cgierror"> + <question> + <para> + Windows: I have installed PHP, but when I to access + a PHP script file via my browser, I get the error: + <programlisting> +cgi error: + The specified CGI application misbehaved by not + returning a complete set of HTTP headers. + The headers it did return are: + </programlisting> + </para> + </question> + <answer> + <para> + This error message means that PHP failed to output anything + at all. To get to see a sensible error message, from the + command line, change to the directory containing the PHP + executable (<filename>php.exe</filename> on Windows) and run + <literal>php -i</literal>. If PHP has any problems running, + then a suitable error message will be displayed which will + give you a clue as to what needs to be done next. If you + get a screen full of html codes (the output of the + <function>phpinfo</function> function) then PHP is working. + </para> + <para> + Once PHP is working at the command line, try accessing the + script via the browser again. If it still fails then it + could be one of the following: + </para> + <itemizedlist> + <listitem> + <simpara> + File permissions on your PHP script, + <filename>php.exe</filename>, <filename>php4ts.dll</filename>, + <filename>php.ini</filename> or any PHP extensions you are + trying to load are such that the anonymous internet user + <literal>ISUR_&lt;machinename&gt;</literal> cannot access them. + </simpara> + </listitem> + <listitem> + <simpara> + The script file does not exist (or possibly isn't where you + think it is relative to your web root directory). Note that + for IIS you can trap this error by ticking the 'check file + exists' box when setting up the script mappings in the + Internet Services Manager. If a script file does not exist + then the server will return a 404 error instead. There is + also the additional benefit that IIS will do any + authentication required for you based on the NTLanMan + permissions on your script file. + </simpara> + </listitem> </itemizedlist> - Make sure you restart Apache, and you now have PHP with MySQL support - using RPM's. Note that it is probably much easier to just build - from the distribution tarball of PHP and follow the instructions in - <filename>INSTALL.REDHAT</filename> found in that distribution. - </para> </answer> </qandaentry> </qandaset>
« previous php.doc (#969337968) next »