fix bug for php5.3