> Just a basic question about session variables.I can't get > them to 100% work as I want. Maybe I don't understand so > that's when it's time to turn to the list :) I want to use > session variables that expire a) when the user closes the > browser OR b) when a session times out,whatever comes first.
Like Bobby said, just enable J2EE session management in the CF Administrator. You don't have to use CFCOOKIE or anything else in that case. > For a) I do (all in Application.cfc): > ... > This makes that sessions expire when user closes browser. No, it doesn't. It ensures that the browser will be disconnected from the session, which has the same result for the user, but the session data will still be consuming memory on the server. That's good enough if your session timeout is short. If your session timeout isn't short, shorten it. There really isn't an effective way to expire the session data on the server when the user closes the browser, since the server doesn't know that the user closed the browser. All the server knows is when you last requested a page. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ Fig Leaf Training: Adobe/Google/Paperthin Certified Partners http://training.figleaf.com/ WebManiacs 2008: the ultimate conference for CF/Flex/AIR developers! http://www.webmaniacsconference.com/ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;192386516;25150098;k Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:304689 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

