[mod_python] Session-Handling mod_publisher

Gregor Kling gregor.kling at dvz.fh-giessen.de
Fri Nov 10 10:09:25 EST 2006


This works:
def start(req):
  c = Cookie.Cookie('HasCookie',"")
  c.expires = time.time() + 60
  Cookie.add_cookie(req,c)
  login_file  =  open('login.html').read() # calls login
  return login_file

def login(req):
  coo = Cookie.get_cookies(req)
  if coo.has_key("hasCookie"):
	dothis
  else:
	dothat

-- 
Gregor Kling

DV-Zentrum
Fachhochschule Giessen
Tel: 0641/309-1292
E-Mail: gregor.kling at dvz.fh-giessen.de


More information about the Mod_python mailing list