Plugin Author
Jonas
(@flinnn)
Hi, this is not available out of the box. Are you familiar with PHP & WordPress filters? If yes this is doable with some custom overwrites.
Best,
Jonas
Thread Starter
s3eed
(@s3eed)
thanks for reply
I worked on modifying the style so that it contains 5 options amount at the top and another button on a line below, and there is enough space to add the +/- button. This is the code I have, so how can I add it?
I have code so I need filter and add to snipper coder to works thanks
<div class="number-input">
<button onclick="this.parentNode.querySelector('input[type=number]').stepDown()" ></button>
<input class="quantity" min="0" name="quantity" value="1" type="number">
<button onclick="this.parentNode.querySelector('input[type=number]').stepUp()" class="plus"></button>
</div>
Plugin Author
Jonas
(@flinnn)
So the process works as follows. Please be aware that this is only for advanced/expert users.
- Remove the comment in line 88 of /includes/templates/wcdp_product_settings.php
- Select “Expert: custom code with action: wcdp_custom_html_amount” in “Layout of Amount suggestions” in the product settings and save the product
- Use the action
wcdp_custom_html_amount
- Make sure that the input field has id=”wcdp-donation-amount” and name=”wcdp-donation-amount”