Wednesday, March 3, 2010

Week 4

This week we looked at cookies and how they are used. Cookies are used to store variables in the users web browser, such as users login are shopping cart items etc. To create a cookie: 
Response.Cookies("CookieName")("VarriableName") = Variable.
To retrieve data from the cookie: 
Request.Cookies("CookieName")("VarriableName").
We then created a Global.asax page and explored what it does. To create it you use the add new item in visual studio and select Global.asax. The Global.asax page allows you to have parts of code that run only at specific points within the life of the website, such as when its initially created or when a session ends etc. We then talked more about arraylists and their properties and methods. We created a test array that utilized its properties and methods and a webpage to run it through. We then continued on with our prototype store. We created another class to get the products that match a category when one is selected. The results were shown in a grid view on the products page.

No comments:

Post a Comment