Copied to clipboard

Flag this post as spam?

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


  • Manu Claessens 23 posts 63 karma points
    Mar 30, 2014 @ 13:22
    Manu Claessens
    0

    Documentation on using cookies

    All,

    Viewing I'm an extremely young Umbraco developer, this is for sure a very 'noobish' question, so bare with me :-)

     

    I'm developing a website with a checkout process consisting of three steps:

    1) Choose a product

    2) Fill in customer information

    3) Overview page with all information and 'order' button

     

    Therefore, I need to pass the information from steps 1 and 2 to step 3, because the overview page will show which product you chose and the information about the customer before he/she clicks on 'confirm order'.

    I was thinking on doing this via cookies, but it seems extremely hard to find good examples on how to use cookies (with razor) in Umbraco.

    Specific questions I would like to have an answer on:

    1) On what page should I initiate the creation of a cookie

    2) How can I initiate the creation of a cookie

    3) How can I retrieve this cookie on the third step to display the chosen information.

     

    Moreover, any information on best practices etc would be very helfpul!

    Again, I know this is a very basic question and there must be documentation on this, but for one reason or the other, the above questions are not answered in the topics I can find. As such, feel free to redirect me to any useful resources.

    Thanks!

    Manu

  • Jeroen Breuer 4908 posts 12265 karma points MVP 5x admin c-trib
    Mar 31, 2014 @ 12:05
    Jeroen Breuer
    0

    Hello,

    Cookies in Razor is just C# so you can find enough info about that. For example: http://www.thecodingguys.net/tutorials/asp/webpages-reading-writing-and-deleting-cookies

    Besides cookies you could also use sessions. 

    Jeroen

Please Sign in or register to post replies

Write your reply to:

Draft