How to remember user's authorization for app on Flickr

Oct 3, 2012 at 2:52 AM

Hi everybody,

I am using Flickrnet api, After user login successful the first time, flickr ask user to authorize my app and the second time login Flickr also ask to authorize my app. So, could you show me how to remember the user has already authorized my app, so that after login Flickr will redirect to my callback url?

Thank you.

Coordinator
Oct 3, 2012 at 10:59 AM

There is no way to get Flickr to autoforward to your callback URL if the user has already authorized your app.

The only workaround is to store the oauth token locally and not redirect the user to Flickr if the token already exists.

Sam

Oct 3, 2012 at 3:16 PM

Hi Sam,

Thank you so much for your help. Currently, I used session to store oAuthAccessToken, but I face to a small problem is when the first user obtain a token and this token was stored in session, and then the second user use my web and now because the session is not timeout (I check session is null to redirect to LoginUrl) -> the second can not login to Flickr to get image and now the first user's image show instead.

- As I know, Facebook automatically detect if the user has already authorized, or Google Api also supported the property (approval_prompt) to control this. Why does not the Flickr support that?

 

Regards,

Truongdc

 

Coordinator
Oct 3, 2012 at 8:00 PM

I don't know why Flickr doesn't support it. It used to work like that but since they moved to OAuth it has stopped auto forwarding.

If you are storing something in the session variable it should be unique to a particular browser.

Sam

Oct 4, 2012 at 2:45 AM

Thanks so much for your support Sam,

Truong