AppStore의 링크 제조업체를 사용하는 앱 링크가 있습니다. 나는 UIWebView
내 애플 리케이션에 있고 UIWebView
에 링크를로드하려고하는데, 그 링크를로드 할 때마다 inbuilt AppStore가 UIWebView
의 컨텐츠를 표시하는 대신 열립니다. inbuilt iOS 앱 스토어를 여는 대신 UIWebView
에 링크를 열려고합니다.UIwebview에서 iOS 앱을 열고 설치하십시오.
내가이 itms-apps://
는 아이폰 OS 시스템이 글을 읽을 때 그 응용 프로그램을 보여주기 위해 앱 스토어를 시작 것이라는 특별한 프로토콜입니다
- (void)viewDidLoad
{
str = @"itms-apps://ax.itunes.apple.com/WebObjects/MZStore.woa";
str = [NSString stringWithFormat:@"%@/wa/viewContentsUserReviews?", str];
str = [NSString stringWithFormat:@"%@type=Purple+Software&id=", str];
// Here is the app id from itunesconnect
str = [NSString stringWithFormat:@"%@289382458", str];
[webOpenApp loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:str]]];
}
-(BOOL) webView:(UIWebView *)inWeb
shouldStartLoadWithRequest:(NSURLRequest *)inRequest
navigationType:(UIWebViewNavigationType)inType
{
if (inType == UIWebViewNavigationTypeOther) {
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:str]];
return NO;
}
return YES;
}
질문에 대한 링크를 추가 할 수 있습니까? 링크에 앱 스토어로 리다이렉트하는 HTML 헤더가 있다면 헤더를 변경할 수 있습니다. 그게 없다면 아무 것도 할 수 없다 –
그 HTML 헤더를 추가하는 샘플을 보내 주시겠습니까? – user3115014