What if one wants to add "onclick" atribute for example. The only way now is to use JavaScript (perhaps it is a better solution in such case) but generally one should be able to add custom attributes. I think there should be an array_merge with Page's $_properties array?

Comments

Posted by Frank Brückner (frosch) on 2011-11-09T11:42:30.000+0000

Code tags added.

Posted by Frank Brückner (frosch) on 2011-11-09T12:00:26.000+0000

{quote}I think there should be an array_merge with Page's $_properties array?{quote}
Bad idea, because not all custom page properties are also allowed HTML attributes! Look at the first example in docs:

{quote}The only way now is to use JavaScript (perhaps it is a better solution in such case){quote}
This is the best solution. We are in 2011 and inline event handlers are from the last millennium. :-)
Use Unobtrusive JavaScript!