Module Settings Overview

Cron job: This option provides you with information on how to set up the CRON job correctly. You can press the How to set up the CRON job? button for more information. If you also wish to receive notification emails when the CRON job is executed, you can check the checkbox underneath the button.

cron

NoteThe CRON daemon is a long running process that executes commands at specific dates and times. OrderReviews uses CRON job service in order to check for completed orders and send emails to customers automatically.

Send BCC to store owner: By enabling this option you will receive an email to your OpenCart email address with a copy from each email OrderReviews sends to a customer.

The following options you can configure an email template that will suite your specific needs.

bcc

General

You can create a new email template from the Add New ReviewMail button or you can choose from the once that you already created.

general

ReviewMail status: This option will enable or disable the selected mail review configuration.

ReviewMail name: This field give you the ability to set a name of the template which will show up on the left column.

Configuration

configuration

Order status: Here you can select the order status at which the selected email review will be sent to the customer.

Customer group: You can specify the customer groups, that will receive selected mail review template.

Message delay: Here you can set after how many days the notification email will be sent.

NoteIf you set the delay to 0, the email will be sent immediately after you run the CRON job and if the conditions are met.

Select orders by: This option specifies how to select orders. You can select them by Date Added or by Date Modified.

Review type: With this option you can choose whether there should be one form for all products in a purchase or each product in the given purchase should have an individual form.

Display images: Enable or disable product images in the email template you send to customes.

Email Template

The following are settings for the Review Email. You can customize the email as you wish.

template

Subject: This option will set the subject of the mail.

Message: Here you can use the text editor to customize the message template.

NoteYou can use shortcodes in order to generalize the message template: With the help of shortcodes you can save a lot of time writing emails. You can say, for example "Hello {first_name} {last_name}" which means that every customer will receive a personalized greeting with their own name in it. There is no need to write personalized emails to each one of your customers.

We will briefly go through each one of the shortcodes:

{first_name} - Inserting it in the email will generate the customer's first name.

{last_name} - This will generate the last name.

{order_products} - This shortcode is used to output the ordered products.

{review_form} - This shortcode will generate a review form in the email itself.

{order_id} - This will show up the Order ID.

{reviewmail_link} - This shortcode will generate a link which can redirect the user to the online form of the email.

preview

Discount Settings

discount

Type of discount: With this option you get to choose which type of discount you want the customer to receive. You have three options:

  • No discount: There will be no discount.

NoteIf you choose this option, you will have to remove the following codes from the mail template: {discount_code}, {discount_value}, {total_amount} and {date_end}.

Note2 If you choose this option, the input fields Discount, Total Amount, Discount validity and Discount mail status will not be available.

  • Fixed amount: Choosing this option will enable you to set a fixed amount with which the customer will be discounted after submitting a review.
  • Percentage: Choosing this option will enable you to set a percentage discount with which the customer will be discounted after submitting a review.

Discount: Here you can set the discount percent or value.

Total amount: With this option you can specify the minimum amount the customer has to spend in order to use the coupon code.

Discount validity: Here you can specify how many days the discount code will be active for after sending the reminder.

Discount mail status: The customer will receive information about their discount, after he/she submits a review, directly in the success page. If you enable this option, however, the customer will also receive an email with the discount information.

NoteEnabling this option will create a second rich text editor at the bottom of the page with which you can create the email template for the discount mail.

Schedule your messages using CRON Jobs

CRON is a time-based job scheduler in UNIX-like operating systems. By means of it, you can schedule tasks (messages, in our case), which are usually referred to as CRON Jobs. Using CRON Jobs allows you to automate your messages and send a given OrderReview email automatically at a given moment in time.

NoteThe explanations on how to set a CRON job here are for cPanel users. Though the process is similar for most web hosting control panels, it might have slight differences. If you need any help setting CRON jobs on a different control panel, feel free to contact iSenseLabs support team for assistance.

ImportantIf your server does not support CRON Jobs, you can try using services such as easycron.com, setcronjob.com or others, which can provide you with this feature.

Setting a CRON Job

First off, you need to navigate to your module's settings. Go to the Control Panel tab. Opposite of the second field (Keep log), you will find a button labeled How to set up the cron job?

Upon clicking it, a modal window will pop up. This window contains the command you need to activate the CRON job (shown in the picture below). Copy it.

cron

This will appear:

how_to_cron

Now, navigate to your cPanel. In the Advanced section, find Cron Jobs and click it.

cpanel

You will be redirected to the following page:

cron_jobs

To add a CRON job, you must first determine how often the CRON job should activate the e-mail-sending script. This is done from the "Common Settings" drop-down menu.

WARNINGMake sure you set the CRON job to at least "Once per day", otherwise you will end up spamming your customers with multiple e-mails a day.

Then, from the Minute and Hour fields, choose the given hour you want the CRON to run at (the values used for the example are 0 and 0, which means the CRON will run at 00:00 every day).

And last but not least, you should paste the command you copied earlier in the "Command" field. It should look something like this:

php/home/orderreviewsdemo/public_html/oc2/vendors/orderreviews/sendEmails.php

ImportantBear in mind the command should not include the "0 0 * * *".

Keep in mind that some servers require the full path to the php extension, which on most of the servers is usr/bin/php. In such cases, you just have to change the beginning of the command from php to usr/bin/php. If this does not make CRON jobs work, it means the php extenion is at a different place (the path is not correct). In that case, contact your hosting provider for more information.

Once you have copied it, click the Add New Cron Job button and the CRON job you have been creating should appear in the Current Cron Jobs section

Functionality

In this chapter we are going to take a look at how the OrderReviews module works. For the following example we have set the OrderReviews module to send review mail when the order status is Complete. Once the administrator changes the order status to Complete, the user will receive a review email. The customer can make the review directly from the email and click the Submit Review button in order to submit it to the store.

received_email

After the customer submits their review, they will be redirected to the Thank you page where they will see information about their coupon code.

submitted

Since we have enabled the Discount mail status option, the customer also receives an email with information about their coupon code.

Now you can go to your Open Cart Admin Panel in Catalog > Reviews and change the status of the customer review from Disabled to Enabled.