If this is your first visit, check our documentation. To post, register or login.
Forums / All Other Contributions/Addons / ZX Order Review [Support Thread]

ZX Order Review [Support Thread]

Started by balihr on 31 Mar 2021, 10:40 AM · Views: 5,655

Results 21 to 24 of 24
16 Jan 2024, 12:00 AM
#21
nicksab avatar

nicksab

Totally Zenned

Join Date:
Apr 2011
Posts:
592
Plugin Contributions:
0

ZX Order Review [Support Thread]

balihr:

Sorry for the late reply, I was on vacation.

Guest checkout is excluded from the order review emails because I personally expect NOT to be contacted about anything other than the essential communication when I choose to checkout as guest. I know it's "just" to review the order, but you could create a very long list of "justs" if you wanted to...

Anyway, if you insist on including Guest orders to this list, you can modify your includes/classes/observers/auto.zx_order_review.php and comment lines 21 and 30:

//if(!zen_in_guest_checkout()) {
$orders_id = $p2;
$customers_email = $p1['customers_email_address'];
$token = RandomToken();
$sql = "INSERT INTO " . TABLE_ORDER_REVIEW . " (orders_id, customers_email, token) VALUES (:ordersID, :customersEmail, :token)";
$sql = $db->bindVars($sql, ':ordersID', $orders_id, 'integer');
$sql = $db->bindVars($sql, ':customersEmail', $customers_email, 'string');
$sql = $db->bindVars($sql, ':token', $token, 'string');
$db->Execute($sql);
//}


Thank you balihr,

I commented the line 21 and 30 as shownand run the order_review.php

However, it didn t work. No emails are being sent to the guest checkout to review their order.

How can i make this work? Asking for reviews manually is a pity for guest account for me. 

Thank you
16 Jan 2024, 8:05 AM
#22
balihr avatar

balihr

Totally Zenned

Join Date:
Oct 2008
Location:
Croatia
Posts:
1,819
Plugin Contributions:
24

Re: ZX Order Review [Support Thread]

It will not work for previously placed orders, only orders that are placed AFTER you modified the code.

You could clone and modify the root/order_review.php file yourself and create a custom query to look up previous orders and send out emails to "old" customers who didn't receive the invite, but this is off topic.

My site - Pro ZC Help
My portfolio | My plugins

17 Jan 2024, 3:29 AM
#23
nicksab avatar

nicksab

Totally Zenned

Join Date:
Apr 2011
Posts:
592
Plugin Contributions:
0

Re: ZX Order Review [Support Thread]

balihr:

It will not work for previously placed orders, only orders that are placed AFTER you modified the code.

You could clone and modify the root/order_review.php file yourself and create a custom query to look up previous orders and send out emails to "old" customers who didn't receive the invite, but this is off topic.

Thank you balihr for the explanation.

5 Feb 2024, 1:46 AM
#24
nicksab avatar

nicksab

Totally Zenned

Join Date:
Apr 2011
Posts:
592
Plugin Contributions:
0

Re: ZX Order Review [Support Thread]

I modified the link so customer are sent directly to our google Page for review instead.

For the html version, i modified line 40 the file /includes/languages/english/bootstrap/email_extras.php with

Line #40 : define('EMAIL_ORDER_MESSAGE','<div id="review-google"><center>Let us know how we did by leaving us your feedback <a href="https://g.page/r/CbK8lN0u0Ic2EBM/review">here</a></center></div>');

However, I can' t figure out how to apply the same changes to plain text version of the email.

I tried developers tool kit with $email but no luck.

Where and/or which file do i need to look at for the plain text version?

Thank you for the assistance with this.