Completed basic implementation of saving (with and without a filename prompt)