fixed the collapse function, refactored LOAD() to use new web2py.js