unified logging, helper functions to log DOMs