This module provides Instagram handler for Video Embed Field.
Users can add Instagram videos to their site by pasting the video's URL into a video embed field.
Simplytest.me link : http://simplytest.me/project/2207411
Project page:
https://drupal.org/sandbox/impol/2207411
http://git.drupal.org/sandbox/impol/2207411.git
GIT
git clone --branch 7.x-1.x http://git.drupal.org/sandbox/impol/2207411.git video_embed_instagram
Automated Review
http://pareview.sh/pareview/httpgitdrupalorgsandboximpol2207411git
Manual reviews of other projects:
1. https://www.drupal.org/node/2526480#comment-10089246
2. https://www.drupal.org/node/2528016#comment-10092286
3. https://www.drupal.org/node/2522976#comment-10092368
Comments
Comment #1
impol CreditAttribution: impol commentedChanged issue's summary following d.org requirements
Comment #2
impol CreditAttribution: impol commentedComment #3
PA robot CreditAttribution: 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
Plazik CreditAttribution: Plazik commentedThank you for module!
Some notes:
$embed = '<iframe src="http://instagram.com/p/' . $id . '/embed/" width=!width height=!height></iframe>';
- use theme() function for HTML code. https://api.drupal.org/api/drupal/includes!theme.inc/function/theme/7Comment #5
impol CreditAttribution: impol commentedComment #6
impol CreditAttribution: impol commentedAdded review comment
Comment #7
impol CreditAttribution: impol commentedReview added.
Comment #8
impol CreditAttribution: impol commentedAdded Simplytest.me link
Comment #9
Chalk CreditAttribution: Chalk commentedHi, Impol!
Small, clean code - module seems to be stable and correct. Perhaps you need to add more features in your module?
Comment #10
dahousecat CreditAttribution: dahousecat commentedHi, Impol,
I agree, code seems clean and everything looks correct.
My only issue was I couldn't actually embed a video but not sure if your module was at fault or if it was user error having not ever used Instagram before.
After having added a Video Embed field I searched for an example Instagram video url to use. I tried with the following 2 urls:
But when I tried to save the node I got the error message:
Video: This video provider is not currently supported.
I'm got to set to needs to work as if it is user error maybe you could include in your documentation how to get the correct URL to use, and if it is not then it needs fixing.
Comment #11
impol CreditAttribution: impol commentedHi, dahousecat. Maybe it's my bad that i don't have provided proper description, but you only need use following urls : http://instagram.com/p/miqK7HMFz3/ or http://instagram.com/p/k0S3FqsFzC/ . No need to paste the raw url to video file :)
Comment #12
impol CreditAttribution: impol commentedI do some research and find that error message toggled from embed_video module.
I added 2 warnings to code, when module can't get the video's thumbnail or video id.
Updated project page.
Comment #13
impol CreditAttribution: impol commentedComment #14
dahousecat CreditAttribution: dahousecat commentedYeah - I had a feeling I was over complicating things!
Thanks for the clarification - works perfectly now.
I think the example URL on the project page is definitely useful - I think it would be a good idea to put this in the readme too.
I can see what Chalk was saying about it being a small module but this post suggests 5 functions and 120 lines of code as a minimum, and you have 6 functions and 160 lines of code so I'm going to go ahead and set RTBC status.
Comment #15
impol CreditAttribution: impol commentedYeah, exactly! I will update readme file, too. It is will be useful for users.
I agree with you, I think this module doesn't need additional functionality. But in my plans create a module for integration instagram with scald and a module that provides the ability to integrate with funny site http://coub.com/
Comment #16
mpdonadioManual Review
Did you ask the Video Embed Field maintainers whether they would entertain this as a submodule (like the FB one that comes with it)?
I think that some may deem the image on the project page a little offensive.
Your settings go straight to the output w/o filtering. Try setting the width to
foo"></iframe><script>alert('XXX');</script>
to see it in action. Risk is mitigated by needing to be able to manage the video styles, which is typically an admin thing, but this is still a problem. And please don't remove the security tag, we keep that for statistics and to show examples of security problems.You should probably validate height and width with the Form API and element_validate_integer_positive, but validation doesn't count as XSS prevention.
Your helper functions should have proper docblocks.
Comment #17
impol CreditAttribution: impol commentedAdded proper comments for helper functions.
Fix some code styles.
#16
I think I don't need to add this module to video embed field project.
Comment #18
PA robot CreditAttribution: PA robot commentedThere are some errors reported by automated review tools, did you already check them? See http://pareview.sh/pareview/httpgitdrupalorgsandboximpol2207411git
I'm a robot and this is an automated message from Project Applications Scraper.
Comment #19
impol CreditAttribution: impol commentedThank you robot, I forgot :)
fixed
Comment #20
impol CreditAttribution: impol commentedComment #21
klausiRemoving review bonus tag, you have not done any manual review, you just repeated the output of an automated review tool. Make sure to read through the source code of the other projects, as requested on the review bonus page.
Comment #22
GrimreaperHello,
I have just reviewed and tested the module. It works.
About the comment #16. I test that there is a verification on the config form, OK. But there is no verification in the template. I do not know if you want to use a check_plain at this moment of the output.
As it is my second application review and there is the question on security, I do not know if I can change the status to RTBC.
Thanks for your module.
Comment #23
naveenvalecha@impol,
As per #16, Did you ask the Video Embed Field maintainers whether they would entertain this as a submodule (like the FB one that comes with it) ?
Would you please open a follow up(by support request in the module issue queue) with the video embed field maintainers regarding whether they would entertain this module also as the submodule ?
I am setting this to 'needs work' for the follow up with video embed field module.Please do it to 'needs review' after follow up.
As I am not a git administrator, so I would recommend you, please help to review other project applications to get a review bonus. This will put you on the high priority list, then git administrators will take a look at your project right away as @klausi mentioned in #21
Comment #24
impol CreditAttribution: impol commentedI think it would be easier to close this project...
I already explained, that I don`t wont to do this module as part of other module(#17), it is my first project on do, why I need to give all my ideas to the video embed field developers.
Comment #25
naveenvalecha@impol,
As the features this module provides is awesome,
Just for decreasing the duplication of the projects on drupal.org I just suggested to ask the video embed field module maintainers.
Please get the review bonus to make your project application in high priority list, then git administrators will take a look at your project right away :-)
Comment #26
mdalda CreditAttribution: mdalda commentedHello @impol and thank you for your work!
video_embed_instagram.module:
Line 183:
You evals if there're matches checking the parameter by reference in preg_match. Instead you can check the returned value by preg_match function.
It returns 1 if matches, 0 if not and FALSE on error.
Hope it helps and thank you.
Comment #27
codesidekick CreditAttribution: codesidekick commentedManual Review
I think this is a good project for a first time contributor to maintain. It's not overly complex, enough people will want to use it (I get a lot of requests for Instagram requests on client projects) and everything is to standard.
No tests written for it, however it's simple enough that it doesn't need them as yet and video_embed_field doesn't have any tests (we really need to get more people to write tests for their contrib projects!).
This review uses the Project Application Review Template.
Comment #28
casivaagustin CreditAttribution: casivaagustin commentedModule looks great, works well.
My comments
In video_embed_instagram.module, line 120 and 150, you are forcing the use of http as protocol. If the website uses https this request to a non https may cause some warnings in the browser and even broke the functionality (more info https://developer.mozilla.org/en-US/docs/Security/MixedContent/How_to_fix_website_with_mixed_content).
It is possible to use // or detect the used protocol in each page load ?
In video_embed_instagram.tpl.php, use check_plain to print $height and $width, any non expected char may break the generated HTML. Don't forget the "" that were mentioned before.
Thank you for the effort, hope to see this module ready soon
Comment #29
impol CreditAttribution: impol commentedHi, casivaagustin
Good comment, I will fix it now
Comment #30
PA robot CreditAttribution: PA robot commentedProject 1: https://www.drupal.org/node/2503707
Project 2: https://www.drupal.org/node/2212035
As successful completion of the project application process results in the applicant being granted the 'Create Full Projects' permission, there is no need to take multiple applications through the process. Once the first application has been successfully approved, then the applicant can promote other projects without review. Because of this, posting multiple applications is not necessary, and results in additional workload for reviewers ... which in turn results in longer wait times for everyone in the queue. With this in mind, your secondary applications have been marked as 'closed(duplicate)', with only one application left open (chosen at random).
If you prefer that we proceed through this review process with a different application than the one which was left open, then feel free to close the 'open' application as a duplicate, and re-open one of the project applications which had been closed.
I'm a robot and this is an automated message from Project Applications Scraper.
Comment #31
impol CreditAttribution: impol commentedFixed all issues.
Comment #32
naveenvalechaDo you still want to contribute this module ? As duplication is no longer a blocker so make this active if you want to ?
Comment #33
naveenvalechaModule is Nice!
Review of the 7.x-1.x branch (commit f69ee3d):
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 :
Rest looks good to me.RTBC :)
Please take a review bonus to come in high priority list
Assigning to heddn to take a final look at this if he has time.
Comment #34
impol CreditAttribution: impol commentedYeah, exactly. It was closed by robot, because I started new project(It's already in status RTBC).
Comment #35
naveenvalecha@impol
Please take review bonus by reviewing 3 project applications.
Comment #36
impol CreditAttribution: impol commentedComment #37
impol CreditAttribution: impol commentedComment #38
impol CreditAttribution: impol commentedComment #39
impol CreditAttribution: impol commented@naveenvalecha Can I get a review bonus now? I am done with 3 reviews.
Comment #40
impol CreditAttribution: impol commentedComment #41
heddnNone of these are blockers, although I'd recommend fixing #2. #2 isn't a blocker because I wasn't able to prove it is a security bug.
Thanks for your contribution, Yauheni!
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.
Comment #42
impol CreditAttribution: impol commentedThanks, heddn!
Will fix at least #2 and #3 before promoting project.