MX Shop Forum :: Order Email Loop?

This thread was displayed: 0 times


Starting with 17th May 2007, Adobe Systems will stop offering support for any version of the discontinued InterAKT products. As a result, we will not answer to new support incidents starting with May 17th, 2007. Pending support incidents will still be followed in order to be closed. The product forums will remain open and be transformed in user-to-user forums. The general forums will be made read-only and not allow new posts or comments.

For more information about the affected products visit: www.interaktonline.com/Support/

View Threaded Show descending
S G
05-17-2007 07:14:18 GMT +2

Hello,

I have followed the instructions from the "Customizing MX Shop PHP" manual and on Page 50 it says to replace this code in the send email trigger:

$emailObj->setContent("Product: {rsOrderDetails.pname_ode}\n\\nPrice:{rsOrderDetails.pprice_ode}\n\\nQuantity: {rsOrderDetails.pquantity_ode}\n\\nProperties: {rsOrderDetails.pproperties_ode}\n");

with this code:

$rsOrderDetails = $GLOBALS['rsOrderDetails'];

$row_rsOrderDetails = $GLOBALS['row_rsOrderDetails'];$message="";

do {$message.= "Name: ".$row_rsOrderDetails['pname_ode']."\nProperties:".$row_rsOrderDetails['pproperties_ode']."\nPrice: ".$row_rsOrderDetails['pprice_ode']."\nQuantity: ".$row_rsOrderDetails['pquantity_ode']."\n\n";}while($row_rsOrderDetails = mysql_fetch_assoc($rsOrderDetails));$emailObj->setContent($message);

The code works fine to loop the product information.  But I would also like to enter information before and after the product loop for each order email.  I would like this information before and after the product loop to be static and NOT loop each time the product info does.  Can you please tell me what I need to add to code to do this?

I am sorry I am packing in all of my support questions, but I know the deadline for MX Shop questions are Tomorrow and I have a store I am trying to have completed by June 1st.

Thank you guys for all of your help so far.......

Sirian

 

Back | Reply | Quote | Top
Ionut MOICIANU
05-17-2007 16:46:28 GMT +2

Hi,

I am not sure I understand the problem - but if you want the message to include some other info outside the loop, you can do like:

$message .= "details here";

do {

//this is the loop

.....

while (...);

$message .= "other details here";

$emailObj->setContent($message);


Ionut

Reply | Quote | Top
S G
05-18-2007 07:39:21 GMT +2

That worked great, thanks Ionut......

Reply | Quote | Top
© Adobe Systems Romania. All rights reserved.