Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


These support forums are now closed for new topics and comments.
Please head on over to http://eureka.ucommerce.net/ for support.

  • Graham Carr 277 posts 389 karma points
    Mar 27, 2012 @ 12:54
    Graham Carr
    0

    Add to basket from CSHTML

    Hi,

    I am using a .cshtml file to display the details of a product and want to put some add to basket functionality into this page. Specifically as the products are unique items, an Add To Basket button, which will add to the basket and then redirect to the basket page.

    My question is how to achieve this, I can see how to do this via the XSLT examples, but can't work out how to achieve this using Razor in the .cshtml file??

    Any help would be much appreciated.

    Graham

  • Søren Spelling Lund 1797 posts 2786 karma points
    Mar 29, 2012 @ 15:18
    Søren Spelling Lund
    0
  • Graham Carr 277 posts 389 karma points
    Apr 02, 2012 @ 16:45
    Graham Carr
    0

    Hi Soren,

    Thanks very much for the informative link. I do have a question though, the Add to Basket functionality in the thread you posted above, whereabouts would this code sit? I have a page called ProductDetails.cshtml which displays the details of the product along with an Add To Basket button, upon clicking this button, what should I do, redirect to another page, or just capture the postback within the ProductDetails.cshtml file, do the functionality specified in the Add To Basket area of the thread above, and then redirect to the basket/cart page?

    Any help on this would be appreciated.

    Cheers,

    Graham

  • Graham Carr 277 posts 389 karma points
    Apr 10, 2012 @ 10:45
    Graham Carr
    0

    Hi,

    Has anyone got any further information as to how to do the following in the above post. As mentioned I am having trouble integrating the code samples provided in the thread Soren posted.

    Cheers,

    Graham

  • Søren Spelling Lund 1797 posts 2786 karma points
    Apr 24, 2012 @ 08:34
    Søren Spelling Lund
    0

    It's you to you whether to redirect or not.

    I typically advocate redirecting when dealing with high value items where customers are not expected to add a lot of different items to the basket. When the reverse is true I generally have the customer stay on the product page or pop up a dialog which lets them decide what to do.

Please Sign in or register to post replies

Write your reply to:

Draft