PHP not working in Web but works in Console

Discussion in 'Installation/Configuration' started by rojozak, Oct 6, 2006.

  1. rojozak

    rojozak New Member

    I've had ISPConfig installed on Ubuntu (Dapper) for about 3 weeks. Everything (seemingly) has worked fine. I've got 2 websites loaded on ISPConfig and email (Postfix) is working fine, as well as Bind DNS.

    I have PHP enabled (Safe Mode off) in both websites but PHP does not work for the websites (tested with a phpinfo file). When I goto the shows the script, rather than running it (you know the drill).

    Anyway, I tried running the phpinfo file from the console, at it works there by running:

    [email protected]: /var/www/web4/ php info.php
    I get the standard phpinfo output. If I try to access it from a browser (locally or remotely) I get the script text.

    [EDIT: I just found...I can access the PHP correctly when remote. So, the problem only appears to be when I try to access the website directly from the server box...using, or localhost, or 192.168.X.XXX these all fail.)]

    My install went smoothly as far as I know. The only change that I made that I can think might have affected anything is to have changed my hostname since install. I also appointed the wrong IP address in my install of ISPConfig. However, everything (except PHP) is working fine.

    (As a result of changing my hostname, I did have to modify my MySQL usertable to add the new hostname).

    Any Ideas? Any log files I should post to help light the way?

    Last edited: Oct 6, 2006
  2. falko

    falko Super Moderator ISPConfig Developer

    You must always use a FQDN to access your web sites. If you have a web site, then you must use in your browser, not the IP address or localhost. ISPConfig creates name-based vhosts.

Share This Page