Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am using Apache server to develop web applications in php . I have one Basic doubt .

Now to execute the php scripts from the browser should I add just this line to httpd.conf

LoadModule php5_module "c:/wamp/bin/php/php5.3.0/php5apache2_2.dll"

or should I add both the lines

LoadModule cgi_module modules/mod_cgi.so
LoadModule php5_module "c:/wamp/bin/php/php5.3.0/php5apache2_2.dll"

Can someone explain the difference . If only one is required then which is faster ?

share|improve this question

2 Answers 2

up vote 1 down vote accepted

If all you're running is PHP scripts within the Apache server, then you only need the php5_module line. On the other hand, if you're running CGI scripts (either PHP or another language) then you need the cgi_module line as well.

share|improve this answer

You don't need to load the cgi_module if you are only developing in PHP.

Just:

LoadModule php5_module "c:/wamp/bin/php/php5.3.0/php5apache2_2.dll"

is sufficient

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.