piątek, 24 grudnia 2010

Blank screen after installation of PHP on apache2

I configured php5 on apache many times so I never expected that I will waste 3 days trying to figure out why I get blank screen when starting apache with php. The configuration was done exactly as stated in "Manual Installation Steps" and "Apache 2.x on Microsoft Windows" in php manual pages.

The interesting thing was that when php was using default settings (when I didn't configure path to php.ini file) all was working ok, but when I provided PHPIniDir directive inside httpd.conf file of apache I got blank screen instead of php script.

So what is the reason ? The reason is that configurations inside php.ini-dist and php.ini-recommended (php.ini-development and php.ini-production in newer releases of php) has :

short_open_tag

set to off..... and inside the test script i used

<?

tag to open php script. When switched to

<?php

all started to work as expected.

sobota, 4 grudnia 2010

Welcome folks... soon I'll place here couple of my thoght regarding different aspects of programming in java and php