cirrus Posted October 1, 2011 Share Posted October 1, 2011 Hi I am trying to put a Conditional Display into the Invoice Created Email does anyone know what the variable is for Product Name I have tried the following $product_service.name $product_service_name $service_product.name $service_product_name Not actually sure if the above variables are related to the Product Name The Product Name I am trying to capture is listed Group Name: Domains Services Type: Other Product/Service Product Name: Annual Domain Name Renewal The conditional display I am trying to get working looks like this {if $product_service_name eq "Annual Domain Name Renewal"} Annual Domain Name Renewal Invoice {else} Web Hosting Invoice {/if} But in the email does not matter what variable I use for the Product Name the text in the email always says Web Hosting Invoice Anyone got any ideas 0 Quote Link to comment Share on other sites More sharing options...
sdemidko Posted October 1, 2011 Share Posted October 1, 2011 I have the following idea: {$invoice_items} is array of items from invoice and should have also the product name try the following code to get the array structure, then you will know how to reach the name {$invoice_items|@print_r} you will see printed array and I guess will have to do something like this: {foreach from=$invoice_items item=value} {if $value.productname eq 'Something'}Output there something{/if} {/foreach} 0 Quote Link to comment Share on other sites More sharing options...
sohouk Posted October 2, 2011 Share Posted October 2, 2011 You will find a bunch of stuff here that will probably help you: http://forum.whmcs.com/showthread.php?t=35804 I have an idea there is now a seperate descriptive product field you could use, but I have not upgraded to the latest version so can't be sure. Trevor 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.