PHP Debug in apache on winXP/win2k

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
Doolittle
Forum Newbie
Posts: 19
Joined: Sun May 04, 2003 11:45 pm

PHP Debug in apache on winXP/win2k

Post by Doolittle »

I have two apache servers, one is ver. 1.3.x on a wi2k machine with php ver. 4.3.1. Another apache server ver. 2 on winxp with php ver. 4.3.1. The problem is when I do the addModule and Loadmodule I get an error when I restart the server. If I don't do that part it works fine... I think my debugging not showing up has to do with this. Whenever there is an error in a page, no debugging errors show up. Is this because of the loadmodule and addmodule? Why do I get an error when I did completely follow the installation instructions?

Thanks for anything
Doolittle
User avatar
volka
DevNet Evangelist
Posts: 8391
Joined: Tue May 07, 2002 9:48 am
Location: Berlin, ger

Post by volka »

what's the error you get?
it might be logged in your apache error.log (unlikely) or the systems eventlog (more likely)
Doolittle
Forum Newbie
Posts: 19
Joined: Sun May 04, 2003 11:45 pm

Post by Doolittle »

Here, this is the error I get...

"Cannot load F:\PHP\sapi\php4apche2.dll into server: The specified module could not be found."

The location is correct too, I've double checked that time and again... Thanks again in advance for any help!
lcidw
Forum Commoner
Posts: 58
Joined: Mon Apr 28, 2003 8:55 am
Location: Netherlands

Post by lcidw »

You probably didn't follow the installation directions from the install.txt (in your PHP package), Read this.. note that php4apache.dll will be php4apache2.dll for you i guess

Code: Select all

Installing PHP for Apache as module
  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

  Now that version 4.1 introduces a safer sapi module, we recommend
  that you configure PHP as a module in Apache.

  To accomplish this, you have to load the php4apache.dll in your
  Apache httpd.conf.

  !! NOTE !!
  Whereever you load php4apache.dll from, php4apache.dll also
  needs the php4ts.dll also included in the PHP4 distribution.
  php4apache.dll depends on php4ts.dll which is loaded as soon as
  Apache loads php4apache.dll. If php4ts.dll can't be found, you
  usually get an error like (also see the "Problems?" section at
  the end of the file):

    Cannot load c:/php/sapi/php4apache.dll into server

  So where does php4ts.dll has to be to be properly loaded ?
  php4ts.dll is searched in the following order:

  1) in the directory where apache.exe is start from
  2) in the directory where php4apache.dll is loaded from
  3) in your %SYSTEMROOT%\System32, %SYSTEMROOT%\system and
     %SYSTEMROOT% directory.
     Note: %SYSTEMROOT%\System32 only applies to Windows NT/2000/XP)
  4) in your whole %PATH%

  Note: What is %SYSTEMROOT% ? Depending on your Windows
        installation this may be for example c:\winnt or C:\windows

  Usually you would just copy it over to %SYSTEMROOT%\System32.
  But if you want to have multiple PHP installations (for
  whatever reason) this is a bad idea. For this circumstance the
  safest thing is to let php4ts.dll reside in the same directory
  where php4apache.dll is loaded from (see point 2 above).
There are many other directions about PHP on Microsoft Windows and IIS in the install.txt, read that file!
Doolittle
Forum Newbie
Posts: 19
Joined: Sun May 04, 2003 11:45 pm

Post by Doolittle »

Ok, I followed all the instructions again... I didn't get an error this time but the debug messages are still not showing up... :(
Doolittle
Forum Newbie
Posts: 19
Joined: Sun May 04, 2003 11:45 pm

Post by Doolittle »

Oops! Im dumb! I needed to turn it on in the php config! Thanks for your patience you guys!
Post Reply