Thread Previous • Date Previous • Date Next • Thread Next |
Wouter Bolsterlee wrote:
My javascript isn't fluent enough to do it like that. Also, sometimes you want to generate it from php, because you need information from a database or something.2009-07-21 klockan 10:42 skrev Sander van Schouwenburg:Wouter Bolsterlee wrote:I'm very interested in the use of extra_attributes. Seriously, what else do you want besides CSS classes for styling or scripting?onclick, onkeyup, onselect, onchange, etc.Hmm, I always attach those from the outside from separate .js files (e.g. using jQuery's .click() function). I don't like mixing behavioral code in markup that is intended to be purely semantic.
Well, actually it means it doesn't matter what you choose and is actually an argument FOR using dashes, because you can mix them.And internally they're changed to underscores anyway.That's an implementation detail and irrelevant to this discussion... ;)
What I actually meant to say was that I switched to using underscores BEFORE I knew they were internally changed anyway. Because I wanted to do $control->extra_attributes = $foo and don't want to be stuck always doing $control->set('extra-attributes', $foo).
But you can go ahead and change it. It doesn't break code. -- Sander
Thread Previous • Date Previous • Date Next • Thread Next |