XML generation for submission