Updated file saving

Added the saving of arrays of spans from the text into XML files
Updated