Synopsis
The FlickrUp module allows to upload photos to Flickr.
The module provides its own field type, widget and formatters.
It allow use Flickr photo as a field.
Similar projects and how they are different
Flickr issue: #124189: Uploading photos to Flickr
Media: Flickr
Differences
The main difference from the other similar modules is uploading photos to Flickr.
Requirements
- Libraries API
- phpFlickr
- Galleria plugin [OPTIONAL. For using Galleria formatter/plugin]
- Using the module is only possible on site accessible from the Internet, because Flickr sends authorization parameters using the domain of your site.
Preview
Format settings


Widget
Upload photo

Uploaded photo

One of formatters

Installation
- Download and install the Libraries API module.
- Download phpFlickr library.Unpack and rename the library directory to "phpflickr" and place it inside the "sites/all/libraries" directory. Make sure the path to the file phpFlickr.php becomes: "sites/all/libraries/phpflickr/phpFlickr.php".
- Download Galleria plugin. Unpack and rename the plugin directory to "galleria" and place it inside the "sites/all/libraries" directory. Make sure the path to the plugin files becomes: "sites/all/libraries/galleria/galleria.js" and "sites/all/libraries/galleria/galleria.min.js".
-
Get Flickr API authorization information: API Key and API Secret from here. You should create a Flickr app. In the Authentication Flow set the following options:
- App Type: Web Application
- Callback URL: http://yourdomain/flickrup/auth
After that, return to the your Drupal site. Set the API Key and API Secret in module settings. Save settings.
Git Repository
git clone --branch 7.x-1.x http://git.drupal.org/project/flickrup.git
cd flickrup
Comments
Comment #1
k0teg commentedThank you for this useful module.
manual review:
Please use the template to describe the project here.
Also I suggest moving js and css files to "js" and "css" folders from "includes".
Comment #2
k0teg commentedManual review:
Comment #3
PA robot commentedWe are currently quite busy with all the project applications and we prefer projects with a review bonus. Please help reviewing and put yourself on the high priority list, then we will take a look at your project right away :-)
Also, you should get your friends, colleagues or other community members involved to review this application. Let them go through the review checklist and post a comment that sets this issue to "needs work" (they found some problems with the project) or "reviewed & tested by the community" (they found no major flaws).
I'm a robot and this is an automated message from Project Applications Scraper.
Comment #4
gunosov commentedThank you for this review.
Fixed
Fixed
A spellchecker not found errors, but spellchecker checks only the spelling but not lexical and other errors :(
It is a way for disabling module “overlay” for my module’s admistrative pages.
The authorization process on the service Flickr is a multistep. After saving the settings form begins first step authentication. Redirect to: flickr.com/services/auth/?api_key=xxxx&perms=delete&api_sig=xxxx. Authorization parameters are passed as GET parameters. When the module "overlay" is enabled, the redirect to:
flickr.com/services/auth/?api_key=xxxx&perms=delete&api_sig=хххх&render=overlay
“&render=overlay” - in the path causes an authorization error. In addition, the Flickr authorization page does not allow embedding within frames. Maybe, this is not the best way to solve this problem, but I do not know how to do it better.
“&render=overlay” parameter is added in the method overlay_drupal_goto_alter (). I considered the possibility of implementing hook_drupal_goto_alter () in my module for remove parameter for some pages, but this has no effect. Maybe because of the modules bootstrap order.
Module "overlay" is evil.
flickrup2_auth() is a page callback for link: http://yourdomain/admin/config/media/flickrup2/auth.
This link should be add to Flickr App authentication flow in callback URL. If the first step of the authorization succeeds, the Flickr call this URL with GET parameter "frob". Also, this link is written on the settings page of the module, if the administrator enters this link, it will redirect to the module settings page. If another user tries to click on this link, it will redirect to frontpage. This link is system and necessary for a specific scenario.
Now I've made edits, and for other users to be "access denied"
P.S.
See more about the process of authorization in Flickr API here: https://www.flickr.com/services/api/auth.spec.html
If anyone knows how to make this module better - welcome :)
Comment #5
gunosov commentedComment #6
gunosov commentedComment #7
gunosov commentedFixed reviws's notes. Added theme for the field.
Comment #8
gunosov commentedComment #9
gunosov commentedComment #10
k0teg commentedThe current version looks very good for me.
One more thing. It's better to use drupal_get_query_parameters instead of relying on $_GET.
Comment #11
k0teg commentedComment #12
k0teg commentedAutomated Review
Review of the 7.x-1.x branch (commit 46b99bb):
This automated report was generated with PAReview.sh, your friendly project application review script. You can also use the online version to check your project. You have to get a review bonus to get a review from me.
Source: http://pareview.sh/ - PAReview.sh online service
Manual Review
The starred items (*) are fairly big issues and warrant going back to Needs Work. Items marked with a plus sign (+) are important and should be addressed before a stable project release. The rest of the comments in the code walkthrough are recommendations.
If added, please don't remove the security tag, we keep that for statistics and to show examples of security problems.
This review uses the Project Application Review Template.
Comment #13
k0teg commentedComment #14
jepster_Automated Review
[Best practice issues identified by pareview.sh] Git default branch is not set, see the documentation on setting a default branch.
Manual Review
The starred items (*) are fairly big issues and warrant going back to Needs Work. Items marked with a plus sign (+) are important and should be addressed before a stable project release. The rest of the comments in the code walkthrough are recommendations.
This review uses the Project Application Review Template.
Comment #15
k0teg commentedI suggest reformatting the issue summary like in here.
Comment #16
gunosov commentedHi Aleh, Peter,
Thank you for your valuable review comments.
Fixed.
The phpFlickr library is released under the GNU General Public License.
The Galleria core and one bundled theme (Classic) is released under the MIT license.
Fixed.
At this moment, there are no available modules for Drupal 7 which uploades photos to Flickr.
Please, read this comment: https://www.drupal.org/node/124189#comment-8867697
In my view, no make sence to integrate my module with the module flickr, because of differencies in structure of the stored data.
The module flickrup (https://drupal.org/project/flickrup) was created for Drupal 5 and 6.
I would say that my module is the next generation of the module flickrup.
Please, explain this item. For theming I use theme functions defined in hook_theme (). Maybe do you mean this:
but I had already remade, as follows:
As far as I know, using the theme functions better than the template files for performance.
Good idea. I'm working on it.
Comment #17
gunosov commentededited
Comment #18
gunosov commentedComment #19
gunosov commentedComment #20
k0teg commentedAutomated Review
Review of the 7.x-1.x branch (commit e65c5f6):
This automated report was generated with PAReview.sh, your friendly project application review script. You can also use the online version to check your project. You have to get a review bonus to get a review from me.
Source: http://pareview.sh/ - PAReview.sh online service
Manual Review
can be replaced with
with hardcoded values.
The starred items (*) are fairly big issues and warrant going back to Needs Work. Items marked with a plus sign (+) are important and should be addressed before a stable project release. The rest of the comments in the code walkthrough are recommendations.
If added, please don't remove the security tag, we keep that for statistics and to show examples of security problems.
This review uses the Project Application Review Template.
Comment #21
gunosov commentedHi Aleh,
Thank you for your review.
Fixed.
Images are replaced by images created by me.
Fixed.
Fixed.
Fixed.
Comment #22
gunosov commentedComment #23
pushpinderchauhan commentedThis sounds like a feature that should live either in Flickr Upload or Flickr project. Module duplication and fragmentation is a huge problem on drupal.org and we prefer collaboration over competition. Please open an issue in the either in Flickr Upload or Flickr project issue queue to discuss what you need. You should also get in contact with the maintainer(s) to offer your help to move the project forward. If you cannot reach the maintainer(s) please follow the abandoned project process. It seems currently both existing modules looking for co-maintainer(s).
If that fails for whatever reason, please get back to us and set this back to "Needs Review".
Comment #24
lolandese commentedSee https://www.drupal.org/node/124189#comment-9409337
Comment #25
gunosov commentedThanks for the reply.
I created the issue "Offering to maintain Flickr Upload" and contacted the current project owner. I'm waiting for response.
Comment #26
Leeteq commentedGreat initiative, much needed :-)
The Flickr Upload module seems abandoned, no activity. It does not seem necessary with "extra patience" to get attention for the takeover, just have a look at the dates in the issue queue:
https://www.drupal.org/project/issues/flickrup
Comment #27
Leeteq commentedCongratulations @gunosov - maintainership of the Flickr Upload module has been transferred :-)
Comment #28
gunosov commentedThanks. I know :)
dev release of FlickrUp for Drupal 7 is already available.
welcome to https://www.drupal.org/project/flickrup
Comment #29
klausiCool, so I think we can continue here with reviewing the code in the flickrup repository.
Comment #30
gunosov commentedgit clone command edited
Comment #31
klausimanual review:
Removing review bonus tag, you can add it again if you have done another 3 reviews of other projects.
Comment #32
gunosov commentedThank you so much for your review klausi. It was really good things you pointed out that I had missed.
Fixed. I removed hook_page_build() implementation and I added CSS file in flickrup_field_formatter_view() using #attached.
This is ajax callback for removing flickrupfield when clicked on remove button. In this callback it will replace field items. Main job to delete field item done in flickrup_submit_handler. flickrup_ajax and flickrup_submit_handler are placed in flickrup.field.inc file. I think it is a good place for these callbacks :)
The authorization process on the service Flickr is a multistep. After saving the settings form begins first step authentication. Redirect to: flickr.com/services/auth/?api_key=xxxx&perms=delete&api_sig=xxxx. Authorization parameters are passed as GET parameters. When the module "overlay" is enabled, the redirect to:
flickr.com/services/auth/?api_key=xxxx&perms=delete&api_sig=хххх&render=overlay
“&render=overlay” - in the path causes an authorization error. “&render=overlay” parameter is added in the method overlay_drupal_goto_alter (). I implemented hook_drupal_goto_alter() and hook_module_implements_alter() in module flickrup for removing that parameter for flickrup's administrative page.
Fixed.
Fixed.
Fixed.
Fixed.
Fixed.
Comment #33
gunosov commentedComment #34
pushpinderchauhan commentedAssigning to myself for next review, which will hopefully be tonight.
Comment #35
pushpinderchauhan commentedAutomated Review
Best practice issues identified by pareview.sh / drupalcs / coder. None
Review of the 7.x-1.x branch (commit e96f96c):
This automated report was generated with PAReview.sh, your friendly project application review script. You can also use the online version to check your project. You have to get a review bonus to get a review from me.
Manual Review
theme_flickrup_field_formatter(): Still arg() exist, comment needed because arg() is evil, and should almost always be avoided.
flickrup_ajax(): why do you access $_POST here? Please add a comment.
But that are not blocking issues.
Also, Blocking issues from #31 have been addressed. I also tested this module functionality w.r.t XSS, CSRF and Sql Injection and it worked as expected. Good Job!
Been sitting at RTBC for a while now, so...
Comment #36
pushpinderchauhan commentedThanks for your contribution, Anton Hunosau!
I updated your account so you can promote this to a full project and also create new projects as either a sandbox or a "full" project.
Here are some recommended readings to help with excellent maintainership:
You can find lots more contributors chatting on IRC in #drupal-contribute. So, come hang out and stay involved!
Thanks, also, for your patience with the review process. Anyone is welcome to participate in the review process. Please consider reviewing other projects that are pending review. I encourage you to learn more about that process and join the group of reviewers.
Thanks to the dedicated reviewer(s) as well.