2017-01-07 14 views
0

내 UIWebView 창 안에 Google 그룹보기가 표시되지만 다른 Google 서비스에 옵션이있는 헤더가 표시됩니다. 머리글을 숨기고 Google 그룹 콘텐츠를 표시하는 방법이 있습니까?UIWebView 내 Google 그룹 헤더 숨기기

이 내가 사용하는 URL입니다 ...

https://groups.google.com/d/forum/MyAppGroupName 

답변

1

사용 UIWebViewDelegate 방법 webViewDidFinishLoad는 이것이

- (void)webViewDidFinishLoad:(UIWebView *)webView { 
NSString *script = [NSString stringWithFormat:@"document.getElementById(\"og_head\").style.display='none';"]; 
[webView stringByEvaluatingJavaScriptFromString:script]; 
} 
+0

덕분에 스크립트를 JS 실행, 작동 enter image description here ArdenDev