> Yes, using <label> will make the labels clickable, but won't do dynamic > style updating. I like the idea of dynamic styling, but just not sure it > belongs in the core framework code -- then users who don't like it or want > to implement it differently will have to disable it. Maybe if it's optional, > and the code is relatively simple. That's sounds reasonable. Core could should be kept simple.
But, is there easy way to do dynamic style update without modifying sqlhtml.py? (Of course I can if I completely rewrite my own widget...) How about putting callbacks and class: LABEL(INPUT(..., _class=XXX, _onclick=YYY), _class=xxx, _onclick=yyy, ...) (or smarter way to do this?) On Thu, Aug 25, 2011 at 01:04, Anthony <abasta...@gmail.com> wrote: > On Wednesday, August 24, 2011 11:50:38 AM UTC-4, ryo1kato wrote: >> >> > I say don't use Javascript if it can be done with a simple html <label> >> > element. >> Right, but I couldn't figure out how for dynamic style update; > > > Yes, using <label> will make the labels clickable, but won't do dynamic > style updating. I like the idea of dynamic styling, but just not sure it > belongs in the core framework code -- then users who don't like it or want > to implement it differently will have to disable it. Maybe if it's optional, > and the code is relatively simple. > > >> >> what's "formstyle"? > > > See http://web2py.com/book/default/chapter/07#SQLFORM (scroll down a bit). > It defaults to table format, but can also be set to ul or divs. However, > radio buttons and checkboxes are always in tables, regardless of formstyle > -- we want to make that more flexible. > > Anthony > -- R.Kato