Sandbox : http://drupal.org/sandbox/johaziel/1821666
Git :

git clone http://git.drupal.org/sandbox/johaziel/1821666.git paypal_field

Drupal 7

This module create a new field type "Paypal field" that gives a payment option to any content type.

Classical exemple:
With a content type 'project', user who create a project and want support or donation.

Comments

riho’s picture

Status: Needs review » Needs work

Hi,
It is recommended that you get a review bonus first to speed up the process.

Then you should fix your git clone line as your example will ask for your password.
Also take a look at the issues found by automated review tools:
http://ventral.org/pareview/httpgitdrupalorgsandboxjohaziel1821666git

Good luck!

ymakux’s picture

Don't use master branch. Create 7.x-1.x, move the project in it

UPD: also please add README.txt

johaziel’s picture

Status: Needs work » Needs review

Changes made and error fixed

git :

git clone http://git.drupal.org/sandbox/johaziel/1821666.git paypal_field

thanks.

riho’s picture

You can edit your first post to change the git line.

Took a look at the module itself as well. It's simple enough and does what it promises.
You have a spelling mistake on line 36 of paypal_field.module - it should be "characters" not "caractere".

Also would be nice to have a way to change the "If you whish to support this project, make a donation !" message per field. A spelling mistake in that one as well, should be "wish" and the space before ! is unnecessary.

I also noticed that the field doesn't work when the Number of values setting is set higher than 1.

ramsonkr’s picture

You must check the data filled by user using the function check_plain().
theme_paypal_field_formatter_paypal_field_default
p tag is not closed.

johaziel’s picture

Added new field text to change the text "If you wish to support this project, make a donation" and give a way to fill what the user want


I also noticed that the field doesn't work when the Number of values setting is set higher than 1.

that because the field was collapsed !

thank you for your comment

cubeinspire’s picture

Status: Needs review » Reviewed & tested by the community
Issue tags: +PAreview: security

This looks quite good.

Just one details from coder :

Line 36: The $string argument to t() should not begin or end with a space. (Drupal Docs)

      $message = t('"%currency" is not a valid currency, you must use 3 characters. eg EUR, USD, ... ', array('%currency' => check_plain($item['paypal_currency'])));

Concerning the form, while it could be made with the form API, as its an external form I don't really see a problem on it. I consider it a false positive.

The biggest problem that I see is that the project page is nearly empty.
I can advise you to read again http://drupal.org/node/997024

I set the security tag for statistic purpose, as #5 has spotted an XSS security issue, knowing that it solved and that there is no blocker issue I guess this is RTBC.

But please solve the last details (specially the project page) before promoting it to a full project.

cubeinspire’s picture

Hi again, as more than a month has passed and I see no opposition I set this as fixed.

Thanks for your contribution, johaziel

I updated your account to let you 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 get 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.

klausi’s picture

Status: Reviewed & tested by the community » Fixed

@cubeinspire: you did not promote the project, right? You assigned the git vetted user role to johaziel. If you do that you can use the template from http://groups.drupal.org/node/184389

manual review:

  1. project page is too short, see http://drupal.org/node/997024
  2. "t('"%mail" is not a valid email address', array('%mail' => check_plain($item['paypal_email'])));": check_plain() is not necessary here, since the "%" placeholder will run check_plain() itself for you. And double escaping is bad, please read the documentation of t() again. Also elsewhere.

But that are no blockers, so the approval was of course fine.

cubeinspire’s picture

@klausi: yes I used a wrong template, I have just edit it.

Automatically closed -- issue fixed for 2 weeks with no activity.

Anonymous’s picture

Issue summary: View changes

change the git line.