fixed text saving for expat