Creating Downloadable Content
Sorry for the silly question, but I am looking at many news apps (The Daily, etc) and they appear to have downloadable Views开发者_如何学编程 or something. The interaction with the views seems a lot like UIViews. Are they using downloadable UIViews or WebViews to see that content? If they are using UIViews, how is this done?
There are at least two approaches you can take when you want to display content from a server.
Implement your UI using iOS UI components. For that you would use
UIView
as a container for the data, aUIActivityIndicator
to show that you are downloading the data from the server, either in form ofXML
orJSON
format. Then you would present those data using iOS UI components such asUITextArea
,UILabel
,UIImageView
and so on.Implement a simple
UIWebView
and give it a url with the content that resides on your web server. The advantage of this solution is that you can manipulate the way the content looks from your server site when the app is already in the App store. You will not be able to do it with the first approach.
Most of the apps use the first approach, but if you don't have much time and want to do it in a dirty fast way use the second approach.
精彩评论