adding diag for php