Hi,

Originally Posted by
scottmaui
I was able to successfully install the template and get it working to show the results, but I had one question I'm hoping someone can help me with.
I want to only show the results of products that were ordered, not show a bunch of products with 0 next to them.
How do a write either javascript or PHP to the effect of...
if product_qty != 0 print product_qty
This can be done with FormMail's Advanced Templates feature, which is available with the Computation Module, but it's not a free product (source code license is currently US$245).
Here's an example of what it would look like:
HTML Code:
<if $product_qty>
Quantity order: $product_qty
</if>
A template cannot use PHP in this way because the template values are inserted after the PHP has been executed on the server.
You might be able to figure out some JavaScript to do this, but it won't be as trivial as an "if" statement and it will only work for users that have JavaScript enabled.
Here's a operational example:
http://www.tectite.com/samples/orderform.htm
Bookmarks