web/data/cubicweb.preferences.js
author sylvain.thenault@logilab.fr
Sat, 04 Apr 2009 15:45:57 +0200
changeset 1238 fa29b5b60107
parent 604 e85042d18b48
child 1419 7ff24154351d
child 1612 0be8605c411a
permissions -rw-r--r--
set 30sec query cache on pyro source, important speedup for pages generating multiple time the same external query

/* toggle visibility of an element by its id
 * & set current visibility status in a cookie
 * XXX whenever used outside of preferences, don't forget to
 *     move me in a more appropriate place
 */
function toggle_and_remember_visibility(elemId, cookiename) {
    jqNode(elemId).toggleClass('hidden');
    async_remote_exec('set_cookie', cookiename,
                      jQuery('#' + elemId).attr('class'));
}