Updated parse_elements functionality, which now works.