I have done a mod on tpl_product_info_display.php in order to have a text link instead of an image as the add_to_cart button.

Below is the piece of code that includes the form and php bits to make the button... For some reason, when you click "buy now" it leads back to the homepage...

What am I missing here?

PHP Code:
<div id="shoppingBar">

<!--bof Form start-->
<?php echo zen_draw_form('cart_quantity'zen_href_link(zen_get_info_page($_GET['products_id']), zen_get_all_get_params(array('action')) . 'action=add_product'), 'post''enctype="multipart/form-data" id="cart_quantity"') . "\n"?>
<!--eof Form start-->

<!--bof Add to Cart Box -->
<?php
if (CUSTOMERS_APPROVAL == and TEXT_LOGIN_FOR_PRICE_BUTTON_REPLACE_SHOWROOM == '') {
  
// do nothing
} else {
?>
<?php
    $display_button 
'<input type="hidden" name="cart_quantity" value="1" />' zen_draw_hidden_field('products_id', (int)$_GET['products_id']);
    if (
$display_button != '') { ?>
    <div class="buyBtn">
    <?php
      
echo $display_button;
    
?>
    </div>
  <?php // display qty and button ?>
<?php 
// CUSTOMERS_APPROVAL == 3 ?>
<!--eof Add to Cart Box-->
    </form>
<!--bof Form close-->
  
<div id="shoppingMainWrapper">

<div id="purchaseButton">
<a href="#" onclick="$('cart_quantity').submit();return false;"><?php echo ADD_TO_SHOPPING_CART;?></a>
</div>

<div id="price">
<!--bof Product Price block -->
<h2 id="productPrices" class="productGeneral">
<?php
// base price
  
if ($show_onetime_charges_description == 'true') {
    
$one_time '<span >' TEXT_ONETIME_CHARGE_SYMBOL TEXT_ONETIME_CHARGE_DESCRIPTION '</span><br />';
  } else {
    
$one_time '';
  }
  echo 
$one_time . ((zen_has_product_attributes_values((int)$_GET['products_id']) and $flag_show_product_info_starting_at == 1) ? TEXT_BASE_PRICE '') . zen_get_products_display_price((int)$_GET['products_id']);
?></h2>
<!--eof Product Price block -->
</div>

</div>

</div>