added php5.3 support