update constructors to php5