Hi developers, the form system along with the admin generator is really a major problem. It doesn't make any sense to work on enhancements (sf 1.3) as long as people are not able to use all of the current features. There are some people complaining about missing features in the form system. There are blog posts out there, for example [1] trying to offer solutions. I think two things play a role in this context:
1. Some things really are missing or can (must) be improved to help solving a lot of problems. 2. Some things only seem to be not or bad supported -- but they probably are simply just not documented. I'll try to explain some problems. One of the most discussed problems seems to be the lack of support for plain fields (display the value instead of an input field) in the admin generator (or rather in the form system). There are workarounds for this but it would be nice to have a solution. I think there are two possible concepts: Either use different widget classes for normal / plain -- or use an additional render method, for example "renderPlain()". There is often a need to change things depending on authentication or credentials so it would also make sense to provide better support for work with the sfUser object. For example sometimes you want to allow editing a field only if the user has a certain credential or you want to not display it when a credential is missing. One problem here is that there must also be a solid concept for the validators as it can easily lead to security wholes when you only "hide" a field but don't prevent the value from being submitted. Another thing is, it would be nice if one could reuse "logical field definition" (combination of widget and validator) for example for things like email, date, or names which are very common and used very often. I don't know but maybe the sfFormField can be extended to also include a validator? or would it make sense to use mergeForm() for such things? (lack of documentation) Also a problem is the formatter stuff. It looks ugly but maybe it's also only a problem of missing documentation? There must be a good way to create "form themes" to render forms using a single echo line where ever possible. Maybe the form rendering can be extended to use a generator with several templates? And maybe it would also be useful to configure the formatters on a class base so it would be possible to configure this on a central place (view.yml?) Next thing is a simple question: How can I unset a form field depending on whether the value of a field is empty or not? And the last one is a feature request: There should be a way to attach arbitrary elements to form fields, so one can have an additional help information or other stuff you need to display along with the fields or the labels. Please, don't click the delete button, instead hear the crys ;-) regards, Matthias [1] http://webmozarts.com/2009/04/12/improving-the-forms/ --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "symfony developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/symfony-devs?hl=en -~----------~----~----~----~------~----~------~--~---
