cookie question

sdlangers

Centurion
Joined
Dec 3, 2002
Messages
118
hi,

im trying to create a type of landing page where i can set a cookie and redirect to another page.. here is the code for the page load:

Visual Basic:
  Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        ' set cookie
        Response.Cookies("salesid").Value = Request("salesid")
        ' redirect
        Response.Redirect(Request("redirect"))
    End Sub

looks simple enough, but it doesnt work - the redirect seems to cause problems with writing the cookie.

is this some sort of security restriction? if so, any ideas for a workaround?

thanks for the help
 
Back
Top