开发者

Google Calendar Mobile Version - embed

I want to embed a google calendar into an iphone app, my webview is fine, except I can't seem to get the URL I need to view the mobile version without having to logging in.

I know its possible as this is done in the twit app (See Screenshot below).

How can I do this?

Lets say the public google calendar is link text and I want to view the Mobile version of this page in a UIView.

The mobile view is available at link text, but you must first be logged into a google account.

Help Stackoverflow!

alt text 开发者_运维问答http://posterous.com/getfile/files.posterous.com/norskben/RtIkoblEW9VsBE07dAQy9Sjjo4aRL2yjCRTCIx316y7ovsCXo9iKeGLL1AMx/photo.jpg


All under control now. Although I didn't find it possible to access the gp mobile view, it turned out infact to be just the agenda view of the normal view.

NSString *gcal = [NSString stringWithFormat:@"<html><meta name=\"viewport\" content=\"width=320\"/><iframe src=\"http://www.google.com/calendar/embed?showTitle=0&amp;showNav=0&amp;showTabs=0&amp;showPrint=0&amp;showCalendars=0&amp;mode=AGENDA&amp;height=600&amp;wkst=2&amp;hl=en_GB&amp;src=northadelaidefitness@gmail.com&amp;color=%23A32929&amp;ctz=Australia%2FAdelaide\" style=\"border-width: 0pt;\" mce_style=\" border-width:0 \" frameborder=\"0\" height=\"400\" width=\"300\"></iframe>"];

[webview loadHTMLString:gcal baseURL:nil];   //load above html string (notice the viewport=320 for iphone resizing
webview.delegate = self; //add delegate for activity access
webview.scalesPageToFit =YES; //scale nicely
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜