Showing results for 
Search instead for 
Did you mean: 

Add % discount to Add to Cart HTML paypal button

New Community Member
Posted on
Hi everyone,

I have tried several times and relied on the code snippets examples provided by paypal ( Yet my button doesn't show any % discount as it should. This is the HTML code snippet, trying to implement a 10% discount (I have just hidden my merchant ID):


<form action="" method="post" onsubmit=" = 'paypal';
discnt = 10;
coupval = '(blanket)';
ReadForm (this);
discnt = 0;">
<input type="hidden" name="cmd" value="_cart" />
<input type="hidden" name="add" value="1" />
<input type="hidden" name="business" value="XXX" />
<input type="hidden" name="item_name" value="Test Item" />
<input type="hidden" name="amount" value="10.00" />
<input type="hidden" name="currency_code" value="USD" />
<input type="hidden" name="lc" value="US" />
<input type="hidden" name="baseamt" value="10.00" />

<input type="image" src="" border="0" name="submit" alt="PayPal – The safer, easier way to pay online!" name="submit" alt="add to cart" />
<img alt="" border="0" src="" width="1" height="1">
<script type="text/javascript">
discnt = 10; // set blanket 10% discount


Does any of you know what am I missing/how to fix it? Thank you so much, take the chance to wish you a good day!

Haven't Found your Answer?

It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.