Binding php with Apache2:

Discussion in 'PHP' started by mrinal700, Feb 28, 2010.

  1. #1
    Hi everybody, I am novice user of php, so plz help me out

    While binding php with Apache2, I got a problem like:

    Add type require at least two arguments, mime type followed by one or more file extensions.

    After adding following lines in httpd.conf file:

    Load Module php5_module "C:/php/php5apache2.dll"
    AddType application/ x-httpd-php.php
     
    mrinal700, Feb 28, 2010 IP
  2. bartolay13

    bartolay13 Active Member

    Messages:
    735
    Likes Received:
    14
    Best Answers:
    1
    Trophy Points:
    98
    #2
    are you installing php to apache???
    i think its not wise to do that, there are many services with apache + php + mysql.
     
    bartolay13, Feb 28, 2010 IP
  3. szalinski

    szalinski Peon

    Messages:
    341
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    0
    #3
    You have a space after application/ , also you need a space before .php; - should be "application/x-httpd-php .php"

    instead of using AddType you should be using AddHandler; for example:

     
    szalinski, Mar 1, 2010 IP