开发者

Reload a page within a specific time interval in a iphone application

In my application, i fetch data from a website in XML format. And after parsing XML file, in my iphone screen i can show some specific message from the website (that message can be updated at any time or a new message can be post in that website at any time).

So, i want to reload the page within a specific time period to show in my application the updated message.

i.e. My application will be auto refresh in after 10sec and give me the updated message list from the website.

Is it possible ?? If, than how it is possible. Please anyone 开发者_运维技巧briefly described it with example.


To auto-refresh you can use a meta refresh tag:

<meta http-equiv="refresh" content="5">

or some javascript, like

setTimeout("location.reload(true)", 10000)

If you're using a javascript framework, there may be other, more graceful ways of doing this.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜