update for php lesser than 5.4