简体   繁体   English

Facebook应用墙的URL方案从网页发布

[英]URL scheme for Facebook app wall Post from web page

I want to post my video link on my facebbok wall, when I view video in iPhone /Android. 当我在iPhone / Android中查看视频时,我想将视频链接发布在facebbok墙上。 For this I have used URL schemes for facebook (fb://post) . 为此,我使用了适用于facebook的URL方案(fb://post)

But for wall post this is not working if any one any idea, how can I do that please share. 但是对于墙贴,如果有任何想法,这是行不通的,请分享我该怎么做。

I want same for linkedIn and google plus also, please help. 我也想对linkedIn和谷歌加同样,请帮助。

I have use this. 我已经用过了 This code will open safari from your app. 此代码将从您的应用中打开Safari。 If you logged in facebook then you will see the desired text and have to press post button to post. 如果您登录了facebook,那么您将看到所需的文本,并且必须按发布按钮才能发布。 If you aren't logged in then it will promote you to login after logging you see the desired text. 如果您尚未登录,则登录后您会看到所需的文本,它将促使您登录。

NSString *shareUrlString = [NSString stringWithFormat:@"https://m.facebook.com/sharer.php?u=%@", urlString];
shareUrlString = [shareUrlString stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding];
NSURL *url = [[NSURL alloc] initWithString:shareUrlString];
[[UIApplication sharedApplication] openURL:url]; 

If want to post in facebook without leaving your app then you have to use facebook sdk or social framework in iOS which is supported in iOS6 or higher. 如果要在不离开应用程序的情况下在Facebook中发布,则必须在iOS6或更高版本中支持的iOS中使用facebook sdk或社交框架。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM