add callback function to php