reimplemented parse_file and renamed parse_xml to parse_str