SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Member
    Join Date
    Mar 2009
    Posts
    3
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    PHP connection to Apache

    Running Windows XP.
    I have installed MySQl 5.051a. Apache 2.2.8 and PHP 5.2.5.
    All on my own PC.

    Apache runs ok. I receive the welcome message.

    But here is the problem I know has been asked a hundred times. But I cannot seem to find the remedy.

    The problem? PHP.
    The software installed in seconds. But is a tough nut to configure. Apache just does not see it as a parser at all. When I run the test file, a message appears asking if I wish to open the file or save it.

    After installing PHP, I added the PHP directory to the Windows Path.

    I also copied the php.ini-recommended file to the C:/php/ root folder, renaming it php.ini

    I have modified the Apache httdp.conf file.

    Any help will be much appreciated.
    I am so keen to get started with PHP and MySQL, but cannot get off the ground -

    kind regards Geoff

  2. #2
    SitePoint Addict
    Join Date
    Dec 2007
    Posts
    358
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Check your httpd.conf, it should have the ScriptAlias, Action, and AddType directives (in case you installing php as CGI):

    http://www.witsuite.com/support/know...apache-service
    I'm creating trouble-free Apache, PHP, MySQL installer, WITSuite,
    and use it to setup my development environment.
    Demo, support, contact. Questions?

  3. #3
    SitePoint Member
    Join Date
    Mar 2009
    Posts
    3
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    hi alex,
    thanks for the reply.

    My attempt to install "PHP, MySQL and Apache" came from a book of the same name. Published by Sams Teach Yourself, the author being Julie C. Meloni. It came with a disc containing all software, and installation.

    But I fail on the PHP configuration.
    And, to be honest, I do not understand your reply.
    But, I thank you all the same.
    Although I have a good background of IT, it is only in HTML.

    I think I will have to abandon the thought of configuring this myself.
    Someone has suggested the download from the WampServer site. Do you know of this product?

    regards, geoff

  4. #4
    SitePoint Addict
    Join Date
    Dec 2007
    Posts
    358
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You wrote:

    When I run the test file, a message appears asking if I wish to open the file or save it.
    Which means that apache does not run PHP to process this test file.

    Most likely this happens because of wrong PHP configuration in httpd.conf.

    Generally, two different approaches exist for adding PHP processing to Apache:
    * adding PHP as module - better performance, less flexible
    * adding PHP as CGI - less performance (however, good enough for local development), more flexible

    The link I've sent you describes how PHP can be added to Apache as CGI.
    For this you need to modify httpd.conf and restart Apache.

    As for WAMP packages, consider this link: http://en.wikipedia.org/wiki/Comparison_of_WAMPs

    I know that many people use XAMPP, but for various reasons I prefer to work with my own, WITSuite.

    Regards,
    Alex
    I'm creating trouble-free Apache, PHP, MySQL installer, WITSuite,
    and use it to setup my development environment.
    Demo, support, contact. Questions?

  5. #5
    SitePoint Member
    Join Date
    Mar 2009
    Posts
    3
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    hi Alex,
    I went for the WAMP download.
    It works a treat. Self-configured no problem at all.
    I am up-and-running. Well ... up and crawling ... so to speak.

    Again, thanks for your email and support.
    I followed your link to wikipedia. Wooh ... too much information!
    I will go into melt-down.

    Stay in touch ... your pal from the UK ... Geoff


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •