大佬教程收集整理的这篇文章主要介绍了从iOS共享Facebook Open Graph Action时出错(不安全链接),大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。
对象创建和共享操作
// ############## OpenGraph - Arrive At a Marina // Photo var photoURL = "" if let image = firstMarina.images.first { photoURL = image.width1440 } else { photoURL = "https://fbstatic-a.akamaihd.net/images/devsite/attachmenT_Blank.png" } let photo = FBSDKSharePhoto(imageURL: NSURL(String: photoURL)!,userGenerated: falsE) // Properties let properties = [ "fb:app_id": "xxxxxxxxxxxxxxxxxxxxx","og:locale": NSLocale.preferredLanguages()[0].StringByreplacingoccurrencesOfString("-",withString: "_"),"og:type": "smartsea:marina","og@R_432_6964@": firstMarina.name!.text,"og:description": firstMarina.desc!.text,"og:image": [photo],"place:LOCATIOn:latitude": firstMarina.LOCATIOn!.lat,"place:LOCATIOn:longitude": firstMarina.LOCATIOn!.lng ] // Object let object = FBSDKShareOpenGraphObject(properties: properties as [NSObject : AnyObject]) // Action let action = FBSDKShareOpenGraphAction(type: "smartsea:arrive_at",object: object,key: "marina") // Content let content = FBSDKShareOpenGraphContent() content.action = action content.previewPropertyName = "marina" // Share FBSDKShareDialog.showFromViewController(self,withContent: content,delegate: self)
Error Domain=com.facebook.Facebook.platform Code=102 "(null)" UserInfo={error_reason=The content you're trying to share includes a link that our security systems detected to be unsafe: https://m.facebook.com/appcenter/smartsea?fbs=9909&fb_object_id=1684374595135519 Please remove this link to conTinue.,error_description=An error occurred during publishing.,app_id=xxxxxxxxxxxxxxxxxxxxx,error_code=102}
奇怪的是,错误URL是一个Facebook域,我没有直接分享这个URl.它似乎是在每次分享行动时产生的.
任何的想法?
谢谢!
以上是大佬教程为你收集整理的从iOS共享Facebook Open Graph Action时出错(不安全链接)全部内容,希望文章能够帮你解决从iOS共享Facebook Open Graph Action时出错(不安全链接)所遇到的程序开发问题。
如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。
本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。