I am looking at building a checkout control for a small shop section of a site, that has a checkout page, customer details and a confirmation page. Then the information is sent to a payment gateway.
I have a couple of classes to manage the shopping cart functionality, ShoppingCart.cs and CartItem.cs. Using just Razor script only, I have managed to render the products, and implemented the add to and remove from cart functionality.
Now I am wondering about how best to tackle the customer details form, and sending the information to the payment gateway.
Any recommendations on how to go about this?
Should I really be creating .NET user controls to handle this? Or can I achieve this via a combination of Razor and .NET user controls?
it's just a matter of preference as I see it. The most common is probably still the "webforms way". Personally I prefer doing this kinds of things either with the help of Contour, or using one or two razor scripts.
Like this script that first displays a form - and then performs a bit of logic on postback:
Is it possible to build a Razor checkout control?
I am looking at building a checkout control for a small shop section of a site, that has a checkout page, customer details and a confirmation page. Then the information is sent to a payment gateway.
I have a couple of classes to manage the shopping cart functionality, ShoppingCart.cs and CartItem.cs. Using just Razor script only, I have managed to render the products, and implemented the add to and remove from cart functionality.
Now I am wondering about how best to tackle the customer details form, and sending the information to the payment gateway.
Any recommendations on how to go about this?
Should I really be creating .NET user controls to handle this? Or can I achieve this via a combination of Razor and .NET user controls?
Hi,
it's just a matter of preference as I see it. The most common is probably still the "webforms way". Personally I prefer doing this kinds of things either with the help of Contour, or using one or two razor scripts.
Like this script that first displays a form - and then performs a bit of logic on postback:
http://joeriks.wordpress.com/2011/01/04/playing-with-razor-in-umbraco-an-old-skool-contact-form/
Hi Jonas
That post is the one that got myself thinking, and so I decided to ask the above question.
is working on a reply...