Added function to loadxml

Not sure if it will work