1
0
Fork 0
mirror of https://github.com/koniu/recoll-webui.git synced 2025-10-03 09:49:25 +02:00

set expires-attribute for cookies

Internet Explorer needs the expires-attribute to be present in order to make the cookies persistent.
This commit is contained in:
dsheyp 2014-10-21 16:38:06 +02:00
parent 15389e8f3b
commit 38f2a84e8e

View file

@ -342,10 +342,10 @@ def settings():
def set():
config = get_config()
for k, v in DEFAULTS.items():
bottle.response.set_cookie(k, str(bottle.request.query.get(k)), max_age=3153600000)
bottle.response.set_cookie(k, str(bottle.request.query.get(k)), max_age=3153600000, expires=3153600000)
for d in config['dirs']:
cookie_name = 'mount_%s' % urllib.quote(d, '')
bottle.response.set_cookie(cookie_name, str(bottle.request.query.get('mount_%s' % d)), max_age=3153600000)
bottle.response.set_cookie(cookie_name, str(bottle.request.query.get('mount_%s' % d)), max_age=3153600000, expires=3153600000)
bottle.redirect('./')
#}}}
#{{{ osd