Jump to content


Photo

Installind php 4 with apache


  • Please log in to reply
6 replies to this topic

#1 craigtb

craigtb
  • Members
  • PipPip
  • Member
  • 24 posts

Posted 13 October 2005 - 09:18 PM

i was trying to install php 4 and apache2 and i got them installed and i need to insert some lines in the httpd.conf file but i cant find that file in the apache folder. i can find httpd text files and other things but no .conf files. when i do find it where do i put these lines?

#2 craigtb

craigtb
  • Members
  • PipPip
  • Member
  • 24 posts

Posted 13 October 2005 - 10:13 PM

I think i got that figured out but i cant find a php4apach2.dll file where is it or can some1 send me one?

#3 craigtb

craigtb
  • Members
  • PipPip
  • Member
  • 24 posts

Posted 14 October 2005 - 12:00 PM

Ok i got all the files but the server still wont connect with the added line
Loadmodule php4_module C:/php/php4apache2.dll
can anyone tell me why it wont work?

#4 wildteen88

wildteen88
  • Staff Alumni
  • Advanced Member
  • 10,482 posts
  • LocationUK, Bournemouth

Posted 14 October 2005 - 07:45 PM

Ok i got all the files but the server still wont connect with the added line

Loadmodule php4_module C:/php/php4apache2.dll
can anyone tell me why it wont work?

if you are using PHP4 then you need to do this to the loadmodule line:
LoadModule php4_module C:/php/sapi/php4apache2.dll
As the php4apache2.dll file should be located in the sapi folder. Also note Loadmodule should have been LoadModule, you had lowercase M and not uppercase M.

#5 craigtb

craigtb
  • Members
  • PipPip
  • Member
  • 24 posts

Posted 14 October 2005 - 09:00 PM

I made it upper case and it still didnt work. The way I installed PHP was froma zip file where you have to place files where they need to be becuase the exe file for some reason wouldnt give me a sapi folder and the php4apache2.dll file. I may of not done it right. I put the php.ini file in the WINDOWS folder and some other file (i think it was a .dll file) in the WINDOWS/SYSTEM folder. and the rest of the files in in the hard drive root folder. Should i do anythign else?


EDIT: where does the code need to be? i put it here
# Example:
# LoadModule foo_module modules/mod_foo.so
#
LoadModule access_module modules/mod_access.so
LoadModule actions_module modules/mod_actions.so
LoadModule alias_module modules/mod_alias.so
LoadModule asis_module modules/mod_asis.so
LoadModule auth_module modules/mod_auth.so
#LoadModule auth_anon_module modules/mod_auth_anon.so
#LoadModule auth_dbm_module modules/mod_auth_dbm.so
#LoadModule auth_digest_module modules/mod_auth_digest.so
LoadModule autoindex_module modules/mod_autoindex.so
#LoadModule cern_meta_module modules/mod_cern_meta.so
LoadModule cgi_module modules/mod_cgi.so
#LoadModule dav_module modules/mod_dav.so
#LoadModule dav_fs_module modules/mod_dav_fs.so
LoadModule dir_module modules/mod_dir.so
LoadModule env_module modules/mod_env.so
#LoadModule expires_module modules/mod_expires.so
#LoadModule file_cache_module modules/mod_file_cache.so
#LoadModule headers_module modules/mod_headers.so
LoadModule imap_module modules/mod_imap.so
LoadModule include_module modules/mod_include.so
#LoadModule info_module modules/mod_info.so
LoadModule isapi_module modules/mod_isapi.so
LoadModule log_config_module modules/mod_log_config.so
LoadModule mime_module modules/mod_mime.so
#LoadModule mime_magic_module modules/mod_mime_magic.so
#LoadModule proxy_module modules/mod_proxy.so
#LoadModule proxy_connect_module modules/mod_proxy_connect.so
#LoadModule proxy_http_module modules/mod_proxy_http.so
#LoadModule proxy_ftp_module modules/mod_proxy_ftp.so
LoadModule negotiation_module modules/mod_negotiation.so
#LoadModule rewrite_module modules/mod_rewrite.so
LoadModule setenvif_module modules/mod_setenvif.so
#LoadModule speling_module modules/mod_speling.so
#LoadModule status_module modules/mod_status.so
#LoadModule unique_id_module modules/mod_unique_id.so
LoadModule userdir_module modules/mod_userdir.so
#LoadModule usertrack_module modules/mod_usertrack.so
#LoadModule vhost_alias_module modules/mod_vhost_alias.so
#LoadModule ssl_module modules/mod_ssl.so
#
LoadModule php4_module C:/php/sapi/php4apache2.dll
the last line

#6 wildteen88

wildteen88
  • Staff Alumni
  • Advanced Member
  • 10,482 posts
  • LocationUK, Bournemouth

Posted 15 October 2005 - 11:07 AM

All you need to do with the zip file is extract all contents to C:\php\ then just copy the php.ini file to C:\WINDOWS\ and that is it! No need ot copy extra .dll's.

NOTE: the php.ini file will be called php.ini-recommended when extract the contents form the zip file, rename it to just php.ini

Also the exe isn't intended to be used fr installing PHP with Apache, the zip file is much more better.

Go here for a good step by step tutotial on installing Apache and PHP. The site includes installation of MySQL and phpMyAdmin too.

#7 craigtb

craigtb
  • Members
  • PipPip
  • Member
  • 24 posts

Posted 15 October 2005 - 05:33 PM

I have done all that and it still wont work. Do i need to place the code in any specific place?




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users