add a message to indicate where overlapping nodes ended up
better error and undo if replace is invalid
enable backslash escaping of tags