Needs work
Project:
Subform Element
Version:
5.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
7 May 2008 at 22:04 UTC
Updated:
10 Jun 2008 at 17:40 UTC
First off, thanks for the very useful module.
I'm using subforms in a 5.x module and need to strip out the node preview and submit buttons.
It looks like this is easily done in 6.x as the element includes the #form property. For 5.x, though, it's more challenging.
Attached is a draft approach that introduces a new property, #strip_buttons. Not sure whether this would be useful or not in 6.x+. If not, it probably doesn't make sense to add a property this late in 5.x that will just be deprecated.
The alternative I guess is a custom module that registers another #after_build and alters the subform there, but it seems like too small a need to justify another module.
Thoughts?
| Comment | File | Size | Author |
|---|---|---|---|
| subform_element-strip-buttons.patch | 1.15 KB | nedjo |
Comments
Comment #1
nedjoComment #2
fagosry for the late response.
I like this idea, but unfortunately your patch works only for buttons placed in the top of the form tree or in the element 'buttons'. So if we add something like this, it should work for the whole form tree I think.
Indeed it's quite late for 5.x, so I'd only add improvements that don't touch the core functionality (like your current patch).