Made a small mistake. Placed the dialog_url adaptation before the Initialize statement. When I change it after running initialize:
if(($success = $client->Initialize())) {
$client->dialog_url = 'http://www.flickr.com/services/oauth/authorize?perms=write';
I get the error:
Oops! There's no "oauth_token" parameter.
Which is the result of a ? instead of a & in the url:
flickr.com/services/oauth/authorize
...
(notice the ? between perms=write and oauth_token=...
I noticed that for Oauth 2.0 you have code who deals with that, hence I used that for a fix I'd like to propose:
On line 1923 of the oauth_client class replace:
$url .= '?oauth_token='.$access_token['value'];
with:
$url = str_replace('{SCOPE}', UrlEncode($this->scope), $url);
$url .= (strpos($url, '?') === false ? '?' : '&').'oauth_token='.$access_token['value'];
And on line 1618 replace:
$this->dialog_url = 'http://www.flickr.com/services/oauth/authorize';
with:
$this->dialog_url = 'http://www.flickr.com/services/oauth/authorize?perms={SCOPE}';
That fixes the flickr issue.
Thanks again for these clases!
Kind regards,
Jasper