Announcement

Collapse
No announcement yet.

Quantity Box and No Quantity Box

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Quantity Box and No Quantity Box

    Within a Act_ProductLine.... page, is there any way to have the quantity set to 1 in the background (without being seen on the page), when using an 'add to cart' button within the product line. I need to mix this style product line with a standard product line showing the 'quantity' button and an 'add to cart' button on the same shop page. The page is set to 'add to cart' within Design | Options | Shop Defaults | Shopping Mode.

    Cheers
    Richard
    http://www.smarterproducts.co.uk

    #2
    If these aren't duplicate products then it's easy. Copy your product template to a new file. Then replace

    NETQUOTEVAR:PRODUCTQUANTITY

    with

    <!-- NETQUOTEVAR:PRODUCTQUANTITY -->
    <input type=hidden name="Q_NETQUOTEVAR:PRODUCTREFERENCE" value="1">

    If you need this to work on Duplicates it's much more tricky.
    Norman - www.drillpine.biz
    Edinburgh, U K / Bitez, Turkey

    Comment


      #3
      Thanks Norman, that's all I needed to finish that section for tonight! Brill.

      Cheers
      Richard
      http://www.smarterproducts.co.uk

      Comment


        #4
        And here's the horribly complex general purpose way that works on both ordinary and duplicate products.

        Replace

        NETQUOTEVAR:PRODUCTQUANTITY

        with
        Code:
        <!-- NETQUOTEVAR:PRODUCTQUANTITY -->
        <script type="text/javascript">
        <!--
         document.write('<input type=hidden value="1" name="Q_' + unescape(('NETQUOTEVAR:PRODUCTANCHOR'.substring(1)).replace(/_/g,'%')) + '">');
        //-->
        </script>
        Norman - www.drillpine.biz
        Edinburgh, U K / Bitez, Turkey

        Comment

        Working...
        X