View Single Post
  #4  
Old 09-27-2004, 07:26 AM
  Jon's Avatar 
Jon Jon is offline
 

X-Guru
  
Join Date: Oct 2002
Location: Vancouver, Canada
Posts: 4,200
 

Default

4.0 doesn't have an add to cart there ?

I pulled some key code from the product.tpl that you can try adding to the products.tpl

No idea if this will work but backup and give it a try

Code:
{* MUST SHOW FORM POST (Note the form name is modified for each product)*} <FORM name="orderform-{$product.productid}" method="post" action="cart.php?mode=add" OnSubmit="javascript: return FormValidation();"> {* MUST SHOW HIDDEN FIELDS *} <INPUT type="hidden" name="productid" value="{$product.productid}"> <INPUT type="hidden" name="cat" value="{$smarty.get.cat|escape:"html"}"> <INPUT type="hidden" name="page" value="{$smarty.get.page|escape:"html"}"> {* To show subscription information *} {if $active_modules.Subscriptions ne "" and $subscription} {include file="modules/Subscriptions/subscription_info.tpl"} {/if} {* To show product options *} {if $active_modules.Product_Options ne ""} { include file="modules/Product_Options/customer_options.tpl"} {/if} {* To show amount text box*} {if $product.distribution eq ""} <input type="text" name="amount"> {/if} {* Submit Button *} {if $js_enabled} {if $smarty.get.pconf ne ""} <INPUT type="hidden" name="slot" value="{$smarty.get.slot}"> <INPUT type="hidden" name="addproductid" value="{$product.productid}"> {include file="buttons/button.tpl" button_title=$lng.lbl_pconf_add_to_configuration style="button" href="javascript:if(FormValidation()) `$ldelim`document.orderform.productid.value='`$smarty.get.pconf`';document.orderform.action='pconf.php';document.orderform.submit()`$rdelim`"} {/if} {if $product.forsale ne "B"} {include file="buttons/add_to_cart.tpl" style="button" href="javascript:if (FormValidation()) document.orderform.submit()"} {else} {$lng.txt_pconf_product_is_bundled} {/if} {else} {include file="submit_wo_js.tpl" value=$lng.lbl_add_to_cart} {/if} {* MUST SHOW FORM END *} </FORM>
Reply With Quote