• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Chapter 14. Cookies > EXERCISES

EXERCISES

1:Create a form that contains a set of checkboxes with different types of coffees—espresso, cappucino, mocha, and so on. Ask the user for his name and room number and to select a type of coffee. Tell him you will be sending the coffee to his room number. Create a cookie to remember his preference. The next time he brings up the page, tell him there is a special rate for his (use the cookie value) favorite coffee.
2:Create a cookie that is assigned the user's favorite color. Change the background color of the document to that color.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint