Author Topic: removing quantity box on product info  (Read 1735 times)

0 Members and 1 Guest are viewing this topic.

David M. Graham

  • Administrator
  • Sr. Member
  • *****
  • Offline Offline
  • Posts: 380
  • Karma: 12
    • View Profile
    • osCommerce University
Re: removing quantity box on product info
« Reply #3 on: September 07, 2008, 12:54:44 PM »
You're welcome Jason.  :)

David

HoosierWeb

  • Web Designers
  • Newbie
  • *****
  • Offline Offline
  • Posts: 7
  • Karma: 1
    • View Profile
    • Hoosier Web
Re: removing quantity box on product info
« Reply #2 on: September 06, 2008, 07:20:35 PM »
Thanks to david.. here is the fix
in the
Code: [Select]
echo TEXT_ENTER_QUANTITY . ":" . tep_draw_input_field('cart_quantity', '1', 'size="6"');  replace with
Code: [Select]
echo  tep_draw_hidden_field('cart_quantity', '1', 'size="6"');
Jason Miller
Hoosier Web
Hosting - CRE Loaded Support - eCommerce http://www.hoosierwebdesigners.com

HoosierWeb

  • Web Designers
  • Newbie
  • *****
  • Offline Offline
  • Posts: 7
  • Karma: 1
    • View Profile
    • Hoosier Web
removing quantity box on product info
« Reply #1 on: September 06, 2008, 04:39:27 PM »
I have a situation where the quantity box is not needed on the product info page.. but the problem is, removing it, breaks the form.. and does not allow the product to be added to the cart.

each product uses attributes so a button coded like so just brings you back to the same product button
Code: [Select]
<?php echo '<a href=" ' tep_href_link(FILENAME_PRODUCT_INFOtep_get_all_get_params(array('action'))
'action=buy_now&products_id=' $product_info['products_id']) . '"><img src="templates/7827/images/buttons/english/button_in_cart.gif" alt="Add to Cart" title=" Add to Cart " type="image" align="absmiddle" border="0"></a>'?>

There has to be a way for the built in button to hide/auto build the action to just add 1.. what am I missing?
Jason Miller
Hoosier Web
Hosting - CRE Loaded Support - eCommerce http://www.hoosierwebdesigners.com