Help: Enable PHP on Mac Server

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Help: Enable PHP on Mac Server

    My friend is developing an application which needs to be tested on Mac Server.

    When trying to browse a .php file in browser, it's not being executed, it's just like a text file.

    In the readme.txt of the application (which is open-source) is written: Enable PHP on Mac Server.

    What does this currently mean and how to solve it?

    Thanks!
    mysterio.al - programming is a functional art

    #2
    you have to install apache 1st in your mac before running php script, perl, cgi, etc... its MAMPP or XAMPP

    apache friends - xampp for mac os x
    Last edited by wapxtech; 03.11.10, 00:15.

    http://wapx.amob.com
    Applications, Games, Wallpapers, Ringtones, Videos, Themes, Screensaver and More!!!

    Comment


      #3
      Thanks for your answer!

      It is installed, but still not working. Seems not configured!
      What can be the next step?
      mysterio.al - programming is a functional art

      Comment


        #4
        it will not work without running the apache , if you install it and dont run it , its useless

        http://wapx.amob.com
        Applications, Games, Wallpapers, Ringtones, Videos, Themes, Screensaver and More!!!

        Comment


          #5
          install mamp on your mac: MAMP: Mac, Apache, MySQL, PHP

          or try to define php extentions in htaccess/php.ini
          Advertise your mobile site for FREE with AdTwirl

          Comment


            #6
            Originally posted by Mysterio3 View Post
            My friend is developing an application which needs to be tested on Mac Server.

            When trying to browse a .php file in browser, it's not being executed, it's just like a text file.

            In the readme.txt of the application (which is open-source) is written: Enable PHP on Mac Server.

            What does this currently mean and how to solve it?

            Thanks!
            PHP is included on Macs with OS X version 10.5+ (Leopard), but it's not enabled
            by default. You have to access the main Apache configuration file and comment
            out a line of code in order to get PHP going. This file is called http.conf, and
            is a hidden file located down inside the Apache install folder.
            You're looking for the following line of code, which has a pound symbol (#) in
            front of it to comment it out:

            #LoadModule php5_module libexec/apache2/libphp5.so

            You need to remove the pound symbol and restart the server to enable PHP. The
            http.conf document is owned by "root," which means you'll have to enter your
            password to change it. You'll probably also want to tweak the php.ini file so that
            Apache uses it. For more detailed information about how to carry out these steps
            and enable PHP, visit Enabling PHP in Mac OS X 10.5 .
            Last edited by MuniGod; 03.11.10, 18:50.

            Comment

            Working...
            X