update of the class implementation with php