yes.
On Oct 5, 1:04 am, annet <[email protected]> wrote: > In my custom _ajax.html file I insert css and js files that are not > needed by every view in the application, therefore I wonder whether it > is possible to use conditionals in response.files.insert(), in that > case .css and .js files are only included when they are really > needed. > > This is what I have in mind: > > {{ > response.files.insert(0,URL(r=request,a='base',c='static',f='base/css/ > reset.css')) > ... > if request.function=='cardexamples': > response.files.insert(3,URL(r=request,a='base',c='static',f='base/ > css/jquery.lightbox-0.5.css')) > response.files.insert(9,URL(r=request,a='base',c='static',f='base/js/ > jquery.lightbox-0.5.js')) > pass > ... > if request.controller=='card' or request.controller=='view': > response.files.insert(10,URL(r=request,a='base',c='static',f='base/ > tiny_mce/tiny_mce.js')) > pass > for _item in response.meta or []:}} > > Kind regards, > > Annet.

