Description

The Parameter Message module allows you to create messages in the CMS with one parameter.
This message can be displayed on the site according to the parameter.

Example:

Configuration (CMS):
Configuration

Site:
Success




Link to Sandbox Project Page
https://www.drupal.org/sandbox/renatog/2838641




Git Clone Command

git clone --branch 7.x-1.x https://git.drupal.org/sandbox/renatog/2838641.git parameter_message
cd parameter_message




Completed Reviews

https://www.drupal.org/node/2833786

https://www.drupal.org/node/2833786#comment-11815447

https://www.drupal.org/node/2834088

https://www.drupal.org/node/2834088#comment-11817426

https://www.drupal.org/node/2831854

https://www.drupal.org/node/2831854#comment-11804617

https://www.drupal.org/node/2833401

https://www.drupal.org/node/2833401#comment-11812829

https://www.drupal.org/node/2833398

https://www.drupal.org/node/2833046

https://www.drupal.org/node/2833444

https://www.drupal.org/node/2834036#comment-11817109

https://www.drupal.org/node/2834029#comment-11817061

https://www.drupal.org/node/2834073#comment-11817343

https://www.drupal.org/node/2834094#comment-11817459

https://www.drupal.org/node/2834066#comment-11817316

https://www.drupal.org/node/2833778

https://www.drupal.org/node/2834102

https://www.drupal.org/node/2833211

https://www.drupal.org/node/2834036

https://www.drupal.org/node/2834029

https://www.drupal.org/node/2833744

https://www.drupal.org/node/2834073

https://www.drupal.org/node/2833387

https://www.drupal.org/node/2833381

https://www.drupal.org/node/2834758

https://www.drupal.org/node/2834764

https://www.drupal.org/node/2833726

https://www.drupal.org/node/2834797

https://www.drupal.org/node/2834783

https://www.drupal.org/node/2826023

https://www.drupal.org/node/2833730

https://www.drupal.org/node/2834821

https://www.drupal.org/node/2834750

https://www.drupal.org/node/2834062

https://www.drupal.org/node/2831764

https://www.drupal.org/node/2831520

https://www.drupal.org/node/2831527

https://www.drupal.org/node/2831163

https://www.drupal.org/node/2828565

https://www.drupal.org/node/2831142

https://www.drupal.org/node/2831116

https://www.drupal.org/node/2831089

https://www.drupal.org/node/2830219

https://www.drupal.org/node/2829952

https://www.drupal.org/node/2828152

https://www.drupal.org/node/2828863

https://www.drupal.org/node/2831225

https://www.drupal.org/node/2831462

https://www.drupal.org/node/2834771

https://www.drupal.org/node/2834793

https://www.drupal.org/node/2832095

https://www.drupal.org/node/2832057

https://www.drupal.org/node/2833454

https://www.drupal.org/node/2831741

https://www.drupal.org/node/2833065

https://www.drupal.org/node/2833046

https://www.drupal.org/node/2831854

https://www.drupal.org/node/2833398

https://www.drupal.org/node/2833401

https://www.drupal.org/node/2833786

https://www.drupal.org/node/2834088

https://www.drupal.org/node/2832534

https://www.drupal.org/node/2833097

https://www.drupal.org/node/2833391

https://www.drupal.org/node/2833654

https://www.drupal.org/node/2833680

https://www.drupal.org/node/2833505

https://www.drupal.org/node/2833714

https://www.drupal.org/node/2833741

https://www.drupal.org/node/2833444

https://www.drupal.org/node/2833778

https://www.drupal.org/node/2833803

https://www.drupal.org/node/2833766

https://www.drupal.org/node/2833658

https://www.drupal.org/node/2833962

https://www.drupal.org/node/2832044

https://www.drupal.org/node/2833430

https://www.drupal.org/node/2834082

https://www.drupal.org/node/2834076

https://www.drupal.org/node/2833970

https://www.drupal.org/node/2831804

https://www.drupal.org/node/2831772

https://www.drupal.org/node/2831700

https://www.drupal.org/node/2831171

https://www.drupal.org/node/2829933

https://www.drupal.org/node/2828776

https://www.drupal.org/node/2828448

https://www.drupal.org/node/2828419

https://www.drupal.org/node/2831863

https://www.drupal.org/node/2832134

https://www.drupal.org/node/2832431

https://www.drupal.org/node/2832474

https://www.drupal.org/node/2832487

https://www.drupal.org/node/2832077

Thanks very much!

Comments

renatog created an issue. See original summary.

renatog’s picture

Issue summary: View changes
renatog’s picture

Issue summary: View changes
renatog’s picture

Issue summary: View changes
renatog’s picture

PA robot’s picture

Issue summary: View changes
Status: Needs review » Needs work

There are some errors reported by automated review tools, did you already check them? See http://pareview.sh/pareview/httpsgitdrupalorgsandboxrenatog2838641git

Fixed the git clone URL in the issue summary for non-maintainer users.

We 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.

renatog’s picture

Assigned: Unassigned » renatog
Status: Needs work » Active
renatog’s picture

Issue summary: View changes
renatog’s picture

Assigned: renatog » Unassigned
Status: Active » Needs review

Hi!

Fixed all items.

Regards.

renatog’s picture

Issue summary: View changes
renatog’s picture

Issue tags: +PAreview: review bonus
renatog’s picture

Issue summary: View changes
renatog’s picture

Issue summary: View changes
gfcamilo’s picture

Status: Needs review » Reviewed & tested by the community

Issue tested.

visabhishek’s picture

Status: Reviewed & tested by the community » Needs review
Issue tags: +PAreview: security
StatusFileSize
new21.28 KB
new34.57 KB

1: Please sanitize data values before display in front-end. If we pass some script as data in admin/config/user-interface/parameter_message , its getting execute

  foreach ($messages_settings as $message_settings) {

    $message = explode('|', $message_settings);

    $parameter       = $message[0];
    $text_message    = $message[1];
    $type            = $message[2];

    $parameter_data  = explode('=', $parameter);

    $parameter_key   = $parameter_data[0];
    $parameter_value = $parameter_data[1];

    if (!empty($_GET[$parameter_key]) && $_GET[$parameter_key] == $parameter_value) {
      drupal_set_message($text_message, $type);
    }
  }

Please see the attach screenshot

2: Please use hook_uninstall to removing used variable instead of hook_install
Example :

/**
 * Implements hook_install().
 */
function parameter_message_install() {
  variable_del('parameter_message_messages');
}

3: Please update readme as https://www.drupal.org/node/2181737

visabhishek’s picture

Status: Needs review » Needs work
renatog’s picture

Status: Needs work » Needs review

Thanks @gfcamilo and @visabhishek.

I fixed all items and commited.

Thank you very much guys!

Regards.

m.abdulqader’s picture

Hello,

Here is my review:

Automated Review
No issues found when testing via pareview

https://pareview.sh/node/538

Manual Review
Individual user account
Yes: Follows the guidelines for individual user accounts.

No duplication
Yes: Does not cause module duplication and/or fragmentation.

Master Branch
Yes: Follows the guidelines for master branch.

Licensing
Yes: Follows the licensing requirements.

3rd party assets/code
Yes: Follows the guidelines for 3rd party assets/code.

README.txt/README.md
Yes: Follows the guidelines for in-project documentation and/or the README Template.

Code long/complex enough for review
No: Does not follow the guidelines for project length and complexity.

Secure code
Yes: Meets the security requirements.

Thanks.

renatog’s picture

Hi @mabdulqader.

Thank you for your review.

Good week.

Regards.

mnishida’s picture

Assigned: Unassigned » mnishida
mnishida’s picture

StatusFileSize
new112.71 KB

After a pair review with the author, @renatog, the issue was tested and its status is: OK.

The issue presented no issues after running PHPCS (Code Sniffer), please see attached screenshot "phpcs.png".

mnishida’s picture

Status: Needs review » Reviewed & tested by the community
mnishida’s picture

Assigned: mnishida » Unassigned
th_tushar’s picture

Status: Reviewed & tested by the community » Postponed
Issue tags: +PAreview: single application approval

Below are the findings in manual review,
1) parameter_message_settings() function should have $form and &$form_state as parameters as it is a Drupal form.
2) In parameter_message_menu() function, remove 'access callback' => 'user_access',, as it is assumed as default by Drupal.
3) Please use hyphens instead of underscore in URL, correct menu path "admin/config/user-interface/parameter_message".

Please fix the above issues. And also,

Code too short
This project is too short to approve you as git vetted user. We are currently discussing how much code we need, but everything with less than 120 lines of code or less than 5 functions cannot be seriously reviewed. However, we can promote this single project manually to a full project for you.

I am postponing this issue for now. Please feel free to set this issue to RTBC, to proceed with single project promotion.

renatog’s picture

Status: Postponed » Reviewed & tested by the community

Perfect @th_tushar.

Thank you very much for your review. I really appreciate all that.

Ok, i understood all the items and i will always work based on them. Thank you.

I fixed all corrections and i committed in branch.

Thank you very much @th_tushar.

Good work.

Regards.

th_tushar’s picture

Status: Reviewed & tested by the community » Fixed

Thanks for your contribution, @renatog!

I have manually promoted this sandbox project to "full" project for you.

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.

renatog’s picture

Perfect @th_tushar.

Thank you very much.

You can let me always. It will be my pleasure.

I will follow all the practices and I will participate more and more contributing.

Always count on me @th_tushar.

Hugs and good work

Status: Fixed » Closed (fixed)

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

avpaderno’s picture

Issue tags: -#ciandt-contrib