3

我想将谷歌日历嵌入到 iphone 应用程序中,我的 webview 很好,但我似乎无法获得无需登录即可查看移动版本所需的 URL。

我知道这是可能的,因为这是在 twit 应用程序中完成的(请参见下面的屏幕截图)。

我怎样才能做到这一点?

假设公共谷歌日历是链接文本,我想在 UIView 中查看此页面的移动版本。

移动视图在链接文本中可用,但您必须先登录到谷歌帐户。

帮助 Stackoverflow!

替代文字 http://posterous.com/getfile/files.posterous.com/norskben/RtIkoblEW9VsBE07dAQy9Sjjo4aRL2yjCRTCIx316y7ovsCXo9iKeGLL1AMx/photo.jpg

4

1 回答 1

1

现在一切都在掌控之中。虽然我发现无法访问 gp 移动视图,但事实证明它只是普通视图的议程视图。

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
于 2010-02-23T18:06:17.450 回答