Flickr 身份验证流程和 iPhone
我正在尝试将我的应用程序连接到 Flickr,但在身份验证过程中遇到问题。
我关注过:
http ://code.flickr.com/blog/2009/11/19/building-authorized-flickr-apps-for-the-iphone/
和
https://github.com/lukhnos/objectiveflickr
我已经为我的应用程序创建了一个 CFBundleURLTypes(我们称之为 myapp://)并测试了它是否有效(即我在 Mobile Safari 中输入 myapp://,我的应用程序就会启动)。我已成功调用 Flickr 中的身份验证 URL,它显示登录信息,要求用户授予我的应用程序必要的权限,然后而不是通过 URL 重定向回我的应用程序:
找不到页面。抱歉:(
在 Flickr 的应用程序身份验证流程下,我将其设置为:“Web 应用程序”并将 URL 设置为 myapp://auth?
但是,看起来(它发生得很快,很难确定)而不是重定向到 myapp ://auth?[with Frob data] 它会转到 http://m.flickr.com/#/myapp://auth?[Frob data]
不确定我做错了什么
编辑:我从调试器复制了 URL 字符串并在桌面上运行它。通过桌面执行此操作时,它正确重定向(尝试启动不存在的应用程序),因此,这似乎只是 Mobile Safari 上的问题。 ?
I'm attempting to hook my application into Flickr but having issues during the Authentication process.
I've followed:
http://code.flickr.com/blog/2009/11/19/building-authorized-flickr-apps-for-the-iphone/
and
https://github.com/lukhnos/objectiveflickr
I've create a CFBundleURLTypes for my application (let's call it myapp://) and tested that it works (i.e. I type myapp:// in Mobile Safari and my application launches). I've successfully called the authentication URL in Flickr, it shows the login, asks the user to grant my app the necessary permissions then instead of redirecting back to my app via my URL gives me:
Page not found. Sorry :(
Under Flickr's Authentication Flow for the application I set it to: "Web Application" and the URL as myapp://auth?
However, it appears (it happens quickly so hard to know for sure) that instead of redirecting to myapp://auth?[with Frob data] it instead goes to http://m.flickr.com/#/myapp://auth?[Frob data]
Not sure what I did incorrectly.
EDIT: I copied the URL string from the Debugger and ran it on the desktop. When doing it through the desktop, it redirected properly (attempting to launch a non-existing app). So, it appears to only be an issue on Mobile Safari?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
问题是自定义方案以数字而不是字母开头。将方案更改为纯 alpha 解决了这个问题。
The issue is that the custom scheme started with a number rather than alpha. Changing the scheme to be pure alpha fixed the issue.