You can do the same thing you did before, you just do it manually.
It looks like you are only using the basic version, right?
You create an HTML form in which the Action is set for the Google validation process, add the corresponding hidden fields (the model your controller will go through will be filled with the correct values ββfor them), and then you have a submit button (or image, if you want to).
So, an example Google Basic HTML page modified for some MVC-ish-ness would be something like this:
<form method="POST" action="https://checkout.google.com/api/checkout/v2/checkoutForm/Merchant/<%= Model.MerchantId %>" accept-charset="utf-8"> <input type="hidden" name="item_name_1" value="<%= Model.Item.Name %>"/> <input type="hidden" name="item_description_1" value="<%= Model.Item.Description %>> <input type="hidden" name="item_quantity_1" value="<%= Model.Item.Quantity %>"/> <input type="hidden" name="item_price_1" value="<%= Model.Item.Price %>"/> <input type="hidden" name="item_currency_1" value="<%= Model.Item.Currency %>"/> <input type="hidden" name="ship_method_name_1" value="<%= Model.Shipping.Price %>"/> <input type="hidden" name="ship_method_price_1" value="<%= Model.Shipping.Price %>"/> <input type="hidden" name="ship_method_currency_1" value="<%= Model.Shipping.Currency %>"/> <input type="hidden" name="tax_rate" value="<%= Model.Tax.Rate %>"/> <input type="hidden" name="tax_us_state" value="<%= Model.Tax.State %>"/> <input type="hidden" name="_charset_"/> <input type="image" name="Google Checkout" alt="Fast checkout through Google" src="http://checkout.google.com/buttons/checkout.gif?merchant_id=<%= Model.MerchantId %>&w=180&h=46&style=white&variant=text&loc=en_US" height="46" width="180"/> </form>
Obviously, you can do everything even more MVC-ish using the Html.Hidden helper, etc., but this shows a really basic version of what you need to do.
Paul
source share