you could also just use the php 'serialize' function to write an array with the information to a file, and 'unserialize' for reading it afterwards.