+ Reply to Thread
Results 1 to 7 of 7

Thread: PHP on Local Host

  1. #1
    Twinkie is offline Banned Twinkie is an unknown quantity at this point
    Join Date
    Sep 2007
    Location
    Ft. Lauderdale, Florida
    Posts
    1,389

    Question PHP on Local Host

    I can't get Apache parse PHP on local host. When I run phpinfo() function, it shows up blank. I am using the automatic PHP installer 5.2, a MySQL server 5.x and Apache 2.2.10 on a Windows Vista 64 bit system, whats wrong? :dunno:

  2. #2
    cursedpsp is offline x10 Sophmore cursedpsp is an unknown quantity at this point
    Join Date
    Apr 2008
    Location
    Wiltshire, England
    Posts
    238

    Re: PHP on Local Host

    What installer did you use?

    If i were you i would install WAMP or XAMPP

    And also
    You say you were using phpinfo(),
    Are you echoing it? Because if you didnt have PHP installed it would be prompting you for a download.

    Try
    echo phpinfo()

  3. #3
    Scoochi2's Avatar
    Scoochi2 is offline x10 Sophmore Scoochi2 is an unknown quantity at this point
    Join Date
    Aug 2008
    Location
    Southport!
    Posts
    185

    Re: PHP on Local Host

    Quote Originally Posted by cursedpsp View Post
    Are you echoing it? Because if you didnt have PHP installed it would be prompting you for a download.

    Try
    echo phpinfo()
    Actually...
    If you are echoing it, DON'T.
    To run phpinfo:
    PHP Code:
    <?php
    phpinfo
    ();
    ?>
    If you get a blank page, I think PHP is working, but you're doing something wrong. If it wasn't working, you would see the PHP code outputting as it is not being parsed. If you get a blank page then *something* is outputting a blank page.
    Last edited by Scoochi2; 11-30-2008 at 05:44 AM.
    If anyone can see it, my post was meant for anyone who reads it. Don't take it personally or think I'm being condescending... :nuts:

  4. #4
    Twinkie is offline Banned Twinkie is an unknown quantity at this point
    Join Date
    Sep 2007
    Location
    Ft. Lauderdale, Florida
    Posts
    1,389

    Re: PHP on Local Host

    I used the installer from php.net. Which installs PHP 5.2.6 only. I think it is being parsed, because it is not showing up as text. As for what I did wrong, how could I go wrong with an installer, I don't know. The mime types are apparently kept in a different file in Apache 2.2.10, so when I use the addtype declaration for PHP, the server refuses to start. I'm using 64 bit, is that a problem?

    Im mad.
    Edit:
    Nope, it shows up blank. It must be parsing it because it is not showing up as text, just a blank page. I used the PHP 5.2.6 installer from php.net. Don't know how an installer could make a mistake? I have a 64 it system, is that a problem?

    I know that the type declaration was put in the mime type file, instead of using the addtype declaration, when I use it Apache refuses to start.
    Last edited by Twinkie; 11-30-2008 at 02:34 PM. Reason: Automerged Doublepost

  5. #5
    supermix is offline x10Hosting Member supermix is an unknown quantity at this point
    Join Date
    Nov 2008
    Posts
    30

    Re: PHP on Local Host

    If you have the time uninstall apache first and reinstall. or I don't know if it has the option of repairing installation to enable php. but if you are in to tweaking ini files I think all you need is to add this line in your httpd.conf.

    AddType application/x-httpd-php .php

    look for similar lines and just add this there. now if it is there but is commented out then just remove the '#' before the line.

    after that you have to restart your apache server.
    Edit:
    I didn't notice the last statement about the 64 bit system. There are no official 64 bit apache and php for windows, only mysql has a 64bit edition for windows.

    I googled this and it might help you but it will be your own risk...

    http://www.elxis.org/guides/develope...l-windows.html
    Last edited by supermix; 12-01-2008 at 10:03 PM. Reason: Automerged Doublepost

  6. #6
    Twinkie is offline Banned Twinkie is an unknown quantity at this point
    Join Date
    Sep 2007
    Location
    Ft. Lauderdale, Florida
    Posts
    1,389

    Re: PHP on Local Host

    I did add that line to the http.config file, it causes Apache to crash. The installer does not use that statement, and instead places the mine types in mime type configuration file. I reinstalled Apache several times with no success.

    Thanks for the info, I'll try it!
    Last edited by Twinkie; 12-04-2008 at 10:10 PM.

  7. #7
    tttony's Avatar
    tttony is offline x10 Sophmore tttony is an unknown quantity at this point
    Join Date
    Jan 2008
    Location
    ~ 10°10'27.10''' N 67°59'59'.59''' O elev. 457m
    Posts
    147

    Re: PHP on Local Host

    I dont recommend install PHP with the installer, its better yourself install PHP manually, thats isnt hard to install I have a tutorial but its in Spanish xD
    PHP & MySQL Web Developer
    Free Domain co.cc

+ Reply to Thread

Similar Threads

  1. currently have an application pending php
    By biomasti in forum Free Hosting
    Replies: 1
    Last Post: 09-03-2008, 01:58 PM
  2. php errors galore
    By DMG Online in forum Scripts & 3rd Party Apps
    Replies: 9
    Last Post: 05-17-2008, 06:23 AM
  3. Local host name
    By gar38 in forum Free Hosting
    Replies: 4
    Last Post: 03-06-2008, 12:54 AM
  4. php problem
    By himgar in forum Free Hosting
    Replies: 1
    Last Post: 02-22-2008, 02:41 AM
  5. "PHP Startup: Invalid Library" - Interesting error
    By javaguy78 in forum Free Hosting
    Replies: 5
    Last Post: 03-27-2007, 02:33 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
x10hosting free hosting for the masses
dedicated servers