0
votes

I have site built in codeigniter framework.

I want to use google checkout. I have used this code to transfer fund but I need something returned so that I can know that transfer is successful and then enter values to my database.

I am not sure how to do that.

Can anyone show me step by step how to do that?

My form :

<form action="https://sandbox.google.com/checkout/api/checkout/v2/checkoutForm/Merchant/xxxxxxx" id="BB_BuyButtonForm" method="post" name="BB_BuyButtonForm" target="_top"> 
    <input name="item_name_1" type="hidden" value="Deposite"/> 
    <input name="item_description_1" type="hidden" value="Money Deposite"/>
    <input name="item_quantity_1" type="hidden" value="1"/>
    <input name="item_price_1" type="text" value="30.0"/>
    <input name="item_currency_1" type="hidden" value="USD"/>
    <input name="_charset_" type="hidden" value="utf-8"/><br />
    <input alt="" src="https://sandbox.google.com/checkout/buttons/buy.gif?merchant_id=xxxxxxxx&amp;w=117&amp;h=48&amp;style=white&amp;variant=text&amp;loc=en_US" type="image"/>
</form>
1

1 Answers

0
votes

...but I need something returned so that I can know that transfer is successful and then enter values to my database...

The Google Checkout API calls that "Part 2" or "Process Checkout Orders".

Here's a tutorial using their Java lib. Note that it doesn't mean you "have" to use this (or any) specific lib, it just shows you the flow.

Other libs are here.