Setup function to save data to local storage.

Still not functioning correctly.
Fixed function to save data to local storage.

Still not working correctly - value's are all saving as null instead of
saving the actual data.