Skip to main content
Inspiring
September 15, 2006
Question

kill session?

  • September 15, 2006
  • 1 reply
  • 215 views
I am wondering how to kill a session.

<% Session.Abandon%>
But this didn't seem to work.

Basically, I'm trying to keep people from going back into their shopping
cart.

However, if the session is killed and the person surfs back to the product
page, would they be able to order in a new session?

<% Session.Content.RemoveAll()%> I tried putting this in a page but I got an
error

---------------------
Microsoft VBScript runtime error '800a01b6'
Object doesn't support this property or method: 'Session.Content'

/0_killsession.asp, line 2
----------------------



This topic has been closed for replies.

1 reply

Inspiring
September 17, 2006
Session.Adandon does work but it does not work when the back button is
pressed as you are not reloading the page from the server using this action.

What you need to do is surround any code on the cart page with an if
statement testing for the existing of the session. Therefore if the person
tries to fire the action again the script will them stop it.

--
Paul Whitham
Certified Dreamweaver MX2004 Professional
Adobe Community Expert - Dreamweaver

Valleybiz Internet Design
www.valleybiz.net

"lee" <lfairban_nospam@amep.com> wrote in message
news:eeekp2$8j1$1@forums.macromedia.com...
>I am wondering how to kill a session.
>
> <% Session.Abandon%>
> But this didn't seem to work.
>
> Basically, I'm trying to keep people from going back into their shopping
> cart.
>
> However, if the session is killed and the person surfs back to the product
> page, would they be able to order in a new session?
>
> <% Session.Content.RemoveAll()%> I tried putting this in a page but I got
> an error
>
> ---------------------
> Microsoft VBScript runtime error '800a01b6'
> Object doesn't support this property or method: 'Session.Content'
>
> /0_killsession.asp, line 2
> ----------------------
>
>
>