beginning of xml + json parser