Add to cart link not working in theme file
-
I am trying to put an add to cart button on an independent theme file. Using the latest version of wp e-commerce
Seems I get a ajax error and nothing happens with trying to add to cart.
Using this code
<form id='product_<?php echo $product_id; ?>' name='product_<?php echo $product_id; ?>' method='post' action onsubmit='submitform(this);return false;' > <?php echo "<div style=''><strong>Member price: </strong> $".get_post_meta($id,'member',true)."</div> "; ?> <input type='hidden' value='add_to_cart' name='wpsc_ajax_action' /> <input type='hidden' value='1' name='quantity' /> <input type='hidden' value='<?php echo $product_id; ?>' name='product_id'/> <input type='submit' style="float:right;" id='product_<?php echo $product_id; ?>_submit_button' class='wpsc_buy_button' name='Buy' value='Add to Cart' /> </form>
- The topic ‘Add to cart link not working in theme file’ is closed to new replies.