View Single Post
  #1  
Old 02-07-2005, 03:09 PM
 
mpj mpj is offline
 

Senior Member
  
Join Date: Feb 2005
Posts: 106
 

Default Replace Quantity drop down to text input box. 4.0+ with buy

Been on this site for a few weeks now, it's about time to give back to the community.


This is for X-Cart 4.0+ with the buy now feature enable.



Skin1>customer>main>product.tpl

Code:
<SELECT id="product_avail" name="amount"{if $active_modules.Product_Options ne '' && $product_options ne ''} onchange="check_wholesale(this.value);"{/if}> {section name=quantity loop=$mq start=$start_quantity} <OPTION value="{%quantity.index%}" {if $smarty.get.quantity eq %quantity.index%}selected{/if}>{%quantity.index%}</OPTION> {/section} </SELECT>

Replace with

Code:
<input type="text" name="amount" size="3" value="1">


Skin1>customer>main>buy_now.tpl

Code:
<SELECT name="amount"> {if $product.min_amount le 1} {assign var="start_quantity" value=1} {else} {assign var="start_quantity" value=$product.min_amount} {/if} {section name=quantity loop=$mq start=$start_quantity} <OPTION value="{%quantity.index%}" {if $smarty.get.quantity eq %quantity.index%}selected{/if}>{%quantity.index%}</OPTION> {/section} </SELECT>

REF: http://forum.x-cart.com/viewtopic.php?t=3117


Happy coding !

MPJ
__________________
X-Cart 4.0.11


{My simple mods}
Adding Market list and % save on product detail
Quantity input box
Reply With Quote