Suiato,
I have just sent the code to Massimo, I dont know if the format I
sent it will be ok, or if the code will be ok. But if you are in a
hurry what you need is actually very simple:
<form action="
https://www.sandbox.paypal.com/cgi-bin/webscr"
method="post">
<!-- Select the correct button depending on country etc.
If you can do it with pregenerated buttons (with prices included
etc)
then so much the better for security -->
<input type="hidden" name="business" value="{{=paypal_id}}" />
<input type="image" src="
https://www.sandbox.paypal.com/es_XC/i/
btn/btn_buynowCC_LG.gif" border="0" name="submit" alt="PayPal - The
safer, easier way to pay online!">
<img alt="" border="0" src="
https://www.sandbox.paypal.com/es_XC/i/
scr/pixel.gif" width="1" height="1">
<form action="
http://www.sandbox.paypal.com/cgi-bin/webscr"
method="post" />
<input type="hidden" name="cmd" value="_cart" />
<input type="hidden" name="upload" value="1" />
<input type="hidden" name="currency_code" value="EUR" />
<input type="hidden" name="display" value="1"/>
<input type="hidden" name="shopping_url" value="
www.google.com"/>
{{k=1}}
{{for id,product in products.items():}}
<input type="hidden" name="item_name_{{=k}}"
value="{{=
product.name}}"/>
<input type="hidden" name="quantity_{{=k}}"
value="{{=session.chart[str(id)]}}"/>
<input type="hidden" name="tax_{{=k}}"
value="{{=product.price*product.tax_rate_in_your_state}}"/>
<input type="hidden" name="amount_{{=k}}"
value="{{=product.price}}"/>
{{k+=1}}
{{pass}}
</form>
This creates a button for you. You should however, start by creating a
sandbox user, then create test accounts for the seller and buyer,
validate both accounts, and then from the seller account, make
yourself a button (so that you have it localised) and put the rest of
the fields missing as you see above.
Actually, I tried to use the encrypted user that the buttons generate,
but it didnt work for me, and had to make the user visible. I will try
further at a later stage, if you find out how to further secure the
button, I'll be happy to learn. I didnt find anything else when
uploading a whole cart with the details without setting up each item
separatedly with their prices in paypal.
Benigno.
On 12 jul, 15:33, suiato <
Homm...@gmail.com> wrote:
> Hi Benigno, thanks for commenting and info onPaypalNVP. I hope to
> be able to try out your code on eStore when it becomes available.
>
> As another e-commerce example, I know EC-CUBE (
http://www.ec-
>
cube.net), which is open-source, written in PHP, and lists support
> for credit payment procedures with Paygent, Webmoney, Softbank payment
> service, GMO payment gateway, F-REGI, Zeus, Sophia, Epsilon and
> remise. Couldn't find support forPaypalor Goole Checkout. Sorry the
> > > with thePaypalEngine that Matt did. (I have the same problem you do,
> > > UK is the only country that gets some of googles love in europe, the
> > > rest go way behind, so no google checkout here either). Actually
> > > Google checkout works only in US, UK (and Canada maybe, if I recall
> > > correctly)
>
> > > Anyways, the Engine that Matt did, does NVP, which allows you to
> > > integratePaypalto a different level than most people probably need
> > > (which is much more simmilar to what Massimo has on hisEStoreapp).
> > > Right now on the Engine that Matt did, you only have the
> > > DoDirectPayment already setup (which is to process the data of a
> > > transaction for which you hold all the customers data including credit
> > > card etc). If you need to do the whole checkout withPaypalwith NVP,
> > > its a longer process, if I remember ok, you actually first stablish a
> > > connection, then you get a token frompaypalvalidating it, you