Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We're retiring the forums!

The SilverStripe forums have passed their heyday. They'll stick around, but will be read only. We'd encourage you to get involved in the community via the following channels instead:

Customising the CMS /

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

1 Form, Multiple Functions for Fields, 1 Submit Button - Possible?

Go to End



Community Member, 18 Posts

28 June 2013 at 11:24am

Edited: 28/06/2013 2:59pm

Hello Stripers,

I have a problem with customizing a form. This is NOT using UserDefinedForms, but creating a custom form into SiteTree. I think. (Still learning, always will)

Currently, I have gotten a form to work as needed with all input fields as I want them. I am also using Bootstrap organize everything on the page, and the problem here becomes that the single form does not allow me to use bootstrap to its full ability, since the entire form becomes one function that I can only call through the ".ss" templates. So I though, why not create each portion of the form into its own function and then call each of them as necessary to allow placing them in the right locations for bootstrapping.

What I'm now trying to figure out is how to have multiple functions but only one submit button that will write data to database for all input fields. Currently the way I've gotten it to work, each form is on its own column via bootstrap, but then each of those functions/forms have their own submit, giving me a total of 4 submit buttons on the same page. Slightly annoying right?

Can someone please help/smackmeoverthehead/point me in the right direction as how to proceed from here? This could be something simple as pushing all data towards a single FormDataEntry Function and write and publish to stage/live. I just haven't been able to get it to work/find a work around.

Any input appreciated and thank you in advanced.



I know there is a module out there called bootstrap forms, but I'm still wondering and curious about getting this to work so that I can have fine tuned control over my functions and where the data will be going to. I can see having to use this in the future, considering the company I'm currently working for has a lot different kinds of data on any one report at anyone time.