support
Administrator
4679 Posts |
Posted - December 10 2006 : 20:25:35
|
Hi,
This requires a modification to paypalgateway.asp.
You will need to replace the paypalGetDatabaseFields sub routine with the following:
Sub paypalGetDatabaseFields Dim Dbc, myname, amount, shippingamount Dim StrSql OpenOrderdb dbc ' Open the database strsql = "select * from orders where orderid=" & oid Set Orders = dbc.execute(strsql) If Not Orders.eof then amount=orders("orderamount") 'this may need to be amount=orders("producttotal") shippingamount=orders("oshipcost")+orders("ohandling")
If CommaAsDecimal="Yes" then Convertamount amount Convertamount shippingamount else amount=formatnumber(amount,2) amount=replace(amount,",","")
shippingamount=formatnumber(shippingamount,2) shippingamount=replace(shippingamount,",","")
end if paypaldofield "amount", amount paypaldofield "shipping", shippingamount
else debugwrite "Cannot find order" end if Closerecordset Orders ShopCloseDatabase dbc end sub
Please note that this may need to be slightly modified in each individual case depending on whether the value of ordertotal in your orders table already accounts for shipping and handling.
As this code may need to be modified depending on each individual's situation, we cannot provide support for it - it is provided simply as a guide to assist those who wish to display their shipping amount separately at Paypal.
Thank you.
Regards, Michael VPASP SUPPORT
|
|
|