Kenny Pollock Posted August 24, 2007 Share Posted August 24, 2007 I integrated our merchandise page with PayPal, and I was curious... how can I have it so if a user selects a size 3XL, 4XL or 5XL t-shirt, it takes the $price variable, and adds a set amount to each one? I want it so that $5 is automatically added to the 5XL, so we don't screw ourselves on underquoting. The $price variable right now is set by user group. If you're a donating member, your price will be $12, if you're a regular member, the price is $15. Any insight is appreciated, thank you! So here's what I have so far: <form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post"> <input type="hidden" name="on0" value="Size" />Size <label for="os0">Size</label> <select name="os0"> <option value="XS">XS</option> <option value="S">S</option> <option value="M">M</option> <option value="L">L</option> <option value="XL">XL</option> <option value="2XL">2XL</option> <option value="3XL">3XL</option> <option value="4XL">4XL</option> <option value="5XL">5XL</option> </select><br /> <input type="hidden" name="on1" value="Username" /> <input type="hidden" name="os1" maxlength="200" value="<?php echo $username; ?>" /> <input type="hidden" name="add" value="1"> <input type="hidden" name="cmd" value="_cart"> <input type="hidden" name="business" value="email"> <input type="hidden" name="item_name" value="Florida Minis Tee - Centered Logo on Black"> <input type="hidden" name="amount" value="<?php echo $price; ?>"> <input type="hidden" name="no_shipping" value="2"> <input type="hidden" name="return" value="http://www.floridaminis.com/thankyou.php"> <input type="hidden" name="no_note" value="1"> <input type="hidden" name="currency_code" value="USD"> <input type="hidden" name="lc" value="US"> <input type="hidden" name="bn" value="PP-ShopCartBF"> <input type="hidden" name="page_style" value="FloridaMinis"> <input type="submit" name="submit" value="Add to cart" /> </form> Link to comment https://forums.phpfreaks.com/topic/66445-integrated-paypal/ Share on other sites More sharing options...
Kenny Pollock Posted August 25, 2007 Author Share Posted August 25, 2007 ??? Link to comment https://forums.phpfreaks.com/topic/66445-integrated-paypal/#findComment-333747 Share on other sites More sharing options...
Kenny Pollock Posted August 31, 2007 Author Share Posted August 31, 2007 Anyone? Link to comment https://forums.phpfreaks.com/topic/66445-integrated-paypal/#findComment-338297 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.