I am working on creating an iphone app that will get it's content from a database. The database will need to be upd开发者_高级运维ated with new records added at least once a week, probably about 3 times a week. Some of the records will need images included in them.
I was going to build an SQLite database and pre-populate it with the base set of data then have the app call out to a web service each time the app opens to check if there are new records and if there are, then pull them down and insert those records in the apps database.
But what's the best way to handle the images that go with some of the records? The images will be small, no more than 20 kb. But they also will be unique, so no two records use the same image.
I'm trying to avoid having to issue an updated app and just let the app grab the new text and images each week.
Any ideas?
Either store the images as BLOB in your database, or download the files with a separate web service and store the filenames in the database.
You could have a web service to get an XML list of all the files, and another one to get the contents of each file. Just loop over them and store them on the device.
精彩评论