I'm trying to integrate Paypal Website Payments Standard into my eStore.
I would like to roll my own solution and cannot make sense of the paypal documentation, its very sprawling and there are so many sections that its confusing to say the least.
I'm not intending to use PDT or IPN I will use the RETURN variable to assess if the payment went through okay or failed.
Maybe at a later date I will integrate PDT and IPN too.
I think I can handle the calling and processing the returns.
But I'm stuck at some very basic levels....
1 - Is this a suitable solution for live use? (no PDT/IPN)
2 - Should I calculate discounts or will paypal do it
(using the NVP)
3 - Should I calculate shipping or will paypal do it
(using the NVP)
4 - Should I calculate taxes or will paypal do it
(using the NVP)
5 - What is the order of execution to calculate discounts?
For example.... Is this right?
If CartDiscountAmount > 0 Then
calculate discount based on fixed discount amount
ElseIf CartDiscountRate > 0 Then
calculate discount based on fixed discount rate
calculate discount based on item discount settings
6 - What is the order of execution to calculate shipping?
For example.... Is this right?
If CartShippingAmount > 0 Then
calculate shipping based on fixed shipping amount
ElseIf CartShippingRate > 0 Then
calculate shipping based on fixed shipping rate
calculate shipping based on item shipping settings
7 - What is the order of execution to calculate taxes?
For example.... Is this right?
If CartTaxAmount > 0 Then
calculate taxes based on fixed tax amount
ElseIf CartTaxRate > 0 Then
calculate taxes based on fixed tax rate
calculate taxes based on item tax settings
I have other questions too, but thought i would start at the beginning and ask the other questions as i go along.
I'm not asking for code samples.
I'm asking for pointers to go in the right direction.
Please dont refer me to the paypal website via links.
Well, after having enough of trawling the Paypal documentation I decided to write to their support department, upon completing and submitting my query, I was presented with a popup and links to some other documentation which looked a lot cleaner and more targetted at what I wanted.
So I wrote the function below to update my cart to the paypal processing server.
Please would someone be kind enough to look at it and point out any errors? and also i'm not sure how to process the options field? Any advice or help there would be greatly appreciated.
Well NVP stands for Named Value Pair, in which you send "Name=Jim" as a NVP
Credit card processing can be separated into these categories
TIPS or MANUAL CHARGE
So you have to AUTH FIRST, then CAPTURE.GET BALANCE is for gift cards. The rest are back end functions, But remember, you always have to capture at some point, like the end of the day.
1. I don't see the purpose for IPN. If a customer has a dispute, they call you first. Why would I want a IPN to tell me they disputed the charge, it should never go there in the first place.
I can't see how PayPal can accurately calculate shipping, sales tax and discounts.
Shipping is based in dimensional and gravitational weight of about 160 lbs and girth of 165. Girth (2x Width + 2x Height)
Each state is different, in California, services are tax free, the state is about 7.0%, my county is .75% for 7.75%. Shipping is non taxable.
Discounts always come off the subtotal before tax and shipping
Well from looking at your code, you seem to be a confident programmer. But take no offense, with all due respect, you seem to have no clue about running a store or a small business, and do not realize how large the scope of calculating Sales tax, shipping and discounts are. There are basic formulas, but someone has to assign the values for every item in the store first in order to calculate them, unless you only sell 1 product. Now you have 48 states, and Alaska and Hawaii which is minimum 2 day air at about $15 to $23 dollars for about 2 pounds and 25 inches of girth.
PayPal is a terrible service to use, and very expensive. If I as a store owner was told I have to use PayPal for my online store, because the programmer told me so, I would laugh. I'm not paying $25 a month plus $3.25 for a AVS lookup, and I think plus 3.7% total for each transaction, plus .25 each per batch capture. If its American Express, Add $5 per month more for $30 a month, plus 3 more points minimum.
Consider having the customer qualify for a merchant processor account first, and that the website you made meets the minimum requirement for approval first. Then select a payment gateway from the available choices.
I wrote this article years ago on payment gateways and merchants processors. I may port it over to a code project tutorial in the future if they let me.
Thank you for taking the time and effort to write a considerable amount of detailed information, its greatly appreciated.
I was devloping the project for myself, and chose paypal because it states that there are no charges for website payments standard except the transactional charges which as you rightly stated are approximately 3 to 4 percent of the total value of the transactionand the most expensive product is under £25 (GBP).
Still, you've given me lots to think about and possibly even seek a readymade cart to implement, although I was really looking to cut costs and hence thats why I opted to have a go at developing a solution to my problem myself.
The issue to do with shipping is definately a major one (for me) as shipping costs vary for shipping to different countries as you so rightly stated.
The reason I opted for paypal was because so many people already have a paypal account (which they use with ebay).
Thank you very much for your input and its made me go back to the drawing board to re-asses everything.
PayPal was the 2nd Payment Gateway I wrote in 2003, first was Verisign, both were CIM. Then I wrote my first real AIM Module for Authorize.net, and wrote AIM ever since. I have potential customers that want CIM, so they don't have to get a SSL certificate.
As far as the EBay factor goes, Magneto seems to be doing a good job at taking the EBay customers. EBay pumped money into them 5 years ago, and then bought the company with their Skype Money. Magneto was smart and charges about $2500 US a year to use the program, they have a lite version that's free to use, but very limited.
Calculating shipping was the hardest program I have ever written. It took me 3 years to figure out how to add up all the mass, and divide it into package units, or pallet units, and then submit each package in a loop for a single quote. I've been running the shipping module for 3 years now, and have got the accuracy up to 99%, always a bit over the actual cost.
So I have this eCommerce program, been working on it for 5 years now, and it's almost ready for mass marketing. I want to change the name of it first and trademark it. I have a few more things to fix like the multi-threaded email delivery system.
I was going to port my program over for European Use, but I don't live in Europe, and I have no clue about shipping companies, payment processors and what languages I need to support.
Let me know what you decide to do. I'm curious to see where the path of least resistance takes you.
I can appreciate that shipping calculation is complex, yet I was under the understanding that the best option to calculate shipping was to take the most common shipping companies ie UPS and DHL (to name two) located within the geographical areas of the sellers and then possibly to register with them for updates on price changes or to write a script that would crawl their website pages (the pages contaning the fee's) and them to save those details in an sql table or xmlrepository and use those figures based uponthe buyers selction of preferred couriers/shipping agents.
Having said that, I must admit I'm not that up on IT and developing having never gone to college or university for formal training. Whatever limited knowledge i have i have gained from hme study after work hours (when employed) or during freetime, from books purchased in the highstreet stores. I must admit I like the mental stimulation of having a problem and trying to resolve it by coming up with your own solution.
I must also admit my solutions arnt always the best hahaha, though I do try. Generally as can be expected I feel the best route is usually the tried and tested text book method, though sometimes its mind-bending to say the least, and now i'm getting older (47) the old brain isnt what it used to be!
As you so rightly stated in your last post, ultimately someone somewhere has to enter the data into the SQL repository (usually the seller i would assume). Alternatively the seller could choose from a predetermined list of shipping charges based uponthe couriers (DHL UPS etc).
As for languages, I'm not very sure but assume that the no one language is universally spoken in all of europe, your bound to find a largeamount of people who dont speak a given language and that the MOST common ones (to my knowledge) are English, German, French and Spanish. I would think if you cover those four then you have close to 70%-90% of the bases covered.
From the way you talk I have no doubt your knowledge of prgramming/devloping is far superior to mine and no offence was taken in your last post where you stated the obvious (that i have no idea of the complexities of shipping etc).
As for letting you knwo which option I choose, I'm still undecided, and unsure what to do next. This is mainly factored to funding being unemployed and (hopefully) between jobs though I dont want to get my hopes high hahaha.
My initial thoughts were that the seller would enter the shipping rates for shipping his/her/their goods to the buyer in a similar fashion to ebay and therfore releasing me from the tedious issue.
I chose website payments standard because its free to begin with apart from the transactional fee's which in all honesty is more or less an everyday thing, what with the way Pay as Go for everything is available now including cable tv and mobile phone coverage and even car insurance can be bought on a daily only basis (though i would imagine its quiet expensive)
I'm still chewing over what route to take, the easiest way out is to obviously purchase a third party product and implement that but its not something i can afford i should imagine.
I guess in the meantime i will keep trawling the net to find a sample that even idiots can implement hahaha
Last Visit: 31-Dec-99 18:00 Last Update: 26-Oct-16 1:43