我坚持在Facebook上分享..Facebook的共享与图像和Applinks
我要的是从我的iOS应用上传的图像,文字和应用链路,可以将用户重定向到安装的应用程序或应用程序商店。
应用链接工作正常,我描述了元标记是这样的:
<meta property="al:ios:url" content="cubeDev://" />
<meta property="al:ios:app_store_id" content="1054030..." />
<meta property="al:ios:app_name" content="My app name" />
<meta property="al:web:should_fallback" content="false" />
<meta property="og:image:width" content="50" />
<meta property="og:image:height" content="50" />
<meta property="og:image" content="https://spb.hh.ru/employer-logo/1625583.png" />
<meta property="og:type" content="website" />
<meta property="og:title" contetn="title" />
<meta property="og:description" content="App description.." />
<meta property="fb:app_id" content="31667067867..." />
分享代码也很简单:
FBSDKShareLinkContent *content = [[FBSDKShareLinkContent alloc] init];
content.contentURL = [NSURL URLWithString:@"http://176.31.132.151:8000/"];
content.imageURL = [feedCell imageURL];
content.quote = [feedCell text];
FBSDKShareDialog *shareDialog = [[FBSDKShareDialog alloc] init];
shareDialog.mode = FBSDKShareDialogModeNative;
if(!shareDialog.canShow) {
shareDialog.mode = FBSDKShareDialogModeFeedBrowser;
}
shareDialog.fromViewController = self;
shareDialog.shareContent = content;
shareDialog.delegate = self;
[shareDialog show];
哪里http://176.31.132.151:8000/是我的应用程序的链接。
看来,当你在meta标签描述图像的应用程序的链接,图像url属性将无法正常工作如..
所以,我的目标是从文本应用程序张贴图片,并且下面的应用程序链接与我的应用程序图标和说明..
将不胜感激的任何帮助。