iOS推特图片 - 我可以在上传之前获取图片网址吗? [英] iOS tweet image - Can I get the image url before upload?

查看:153
本文介绍了iOS推特图片 - 我可以在上传之前获取图片网址吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想要能够通过twitter / Facebook /电子邮件等从我的应用程序共享图像。
可能有几百种不同的方法来做到这一点非常简单。
但是我需要/想要做的是允许其他人直接打开图像(如果已安装)。

I want to be able to share images from my app on twitter/facebook/email etc.. There's probably hundreds of different ways to do this which is quite simple. However what I need/want to do, is allow the images to be opened by other people straight into my app (If they have it installed).

所以我有一个url计划,所以url将打开我的应用程序与这样的图像:

So I have a url scheme so a url will open my app with an image like this:

myurlscheme://image?url=http://imageurl.com

我遇到的问题是上传图像的过程,但是将我的网址计划添加到网址的开头。

The problem I have, is the process for uploading the image, but adding my url scheme to the beginning of the url.

如果我能知道在发送推文之前要使用的url twitter / facebook,我可以添加我的url方案到图像的前端url并把它放在tweet。我猜这可能是不可能的。

If I could know the url twitter/facebook is going to use before I send the tweet, I could add my url scheme to the front of the image url and put it in the tweet. I'm guessing this might not be possible though.

另一个想法是将图像上传到另一个服务,获取url,然后撰写并发送推文。有没有合适的服务呢? (最好是免费服务)我真的不想自己托管图像。

Another thought is to upload the image to another service, get the url, then compose and send the tweet. Are there any suitable services for doing this? (Preferably free services) I dont really want to have to host the images myself.

谢谢

推荐答案

1)在上传图片之前,我没有看到您打算创建图片网址的方式,这是鸡/鸡蛋的情况。上传到Facebook,Twitter等等之后,我建议您查看一个实际的图片网址,并尝试找出上传的下一张图片的一个字符。关于twitter具体来说,图片网址也将根据上传服务的使用情况而有所不同。

1) I don't see how you plan on conjuring an image URL before you upload the image - that is a chicken/egg situation. I would recommend taking a look at an actual image URL after you upload it to facebook, twitter, etc and try to figure out even one character of what it would be for the next image you upload. Regarding twitter specifically the image URL is also going to vary depending on what upload service is being used.

2)关于上传图片和获取网址,为什么不看看点击进入 flickr API

2) regarding uploading the image and getting the URL why not look into tapping into the flickr API?

这篇关于iOS推特图片 - 我可以在上传之前获取图片网址吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆