Added xmlSafe() and replacePlaceholders()