Jump to content

pls pls help me figure dis out->error in apache n php config settings


Recommended Posts

Hi

i loaded apache 1.3.24 and php 4.3.2 into my drive D

i made the following changes in the httpd.conf file

 

i had set while installing php,the following location for storing my PHP files

D:/php/projects

So i made this change in

DocumentRoot "D:/php/projects"

<Directory "D:/php/projects">

ScriptAlias /php/ "D:/php/"

AddType application/x-httpd .php

    AddType application/x-httpd-php "/php/php.exe"

    AddType application/x-httpd-php-source .phps

     AddType application/x-tar .tgz

LoadModule php4_module "d:/php/sapi/php4apache2.dll->1033

 

But when i starrt my apache, it displays the following error message->

Syntax error on line 1033 of d:/apache group/apache/conf/httpd.conf:

Cannot load d:/php/sapi/php4apache2.dll into server: (1157) One of the library f

iles needed to run this application cannot be found

 

now wen i remove LoadModule php4_module "d:/php/sapi/php4apache2.dll and put it in the load module lines with # and run the apache,it doesnt giv any error,but wen i try to test  my test.php, the browser displays a pop up window saying : you are downloading file from test.php would u like to save,open... wen i click open,it jus keeps loopin n loopin by displayin the same pop up...

Wat did i do wrong? is it in my http.conf file??

:-[

Link to comment
Share on other sites

Just adding the following few lines should be sufficient:

 

Add the following line at the end of the LoadModules list (do not add a # at the start of the line (lines starting with a # are considered comments and are ignored))

LoadModule php4_module "D:/php/sapi/php4apache2.dll"

 

 

Scroll down and add the following few lines near the AddType's

AddType application/x-httpd .php

AddType application/x-httpd-php-source .phps

 

No need to apply a script alias if you are loading PHP as an Apache Module.

Link to comment
Share on other sites

i did wat u said, but there's something wrong in wat i'm doing. After tyrpin the loadmodule, n starting the apache, it gives the error that it cannot load and that one of lib fxn needed to run it,cant be found???

which lib file??

i checked my error log file and it says..[error] [client 127.0.0.1] no acceptable variant: d:/apache group/apache/htdocs/index.html

Link to comment
Share on other sites

Hold on, You are using Apache1.3.x however you are trying to load an Apache module called php4Apache2.dll

 

That module is for use with Apache2.0.x only. You should be loading php4apache.dll. Your LoadModule line should be:

LoadModule php4_module "D:/php/sapi/php4apache.dll"

Link to comment
Share on other sites

yes dat was it..well the error has gone..

but my test.php aint working..i type in the browser,http://localhost

it then displays,an index html,and shows my test.php. On clicking it,the browser displays a pop up window saying : you are downloading file from test.php would u like to save,open... wen i click open,it jus keeps loopin n loopin by displayin the same pop up...wats wrong? is it cos of the config setting??

 

 

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.