Updated tpls and saving

Updated the way the table headers build. Fixed the way the table data
saves.