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.

All other Modules /

Discuss all other Modules here.

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

UserForms issue when creating my own form fields


Reply


757 Views

Avatar
MarcusDalgren

Community Member, 288 Posts

6 October 2009 at 12:43am

Hi.

I've been using the UserForms module to allow my client to create their own form fields on their site.
In order for it to work properly I've had to create a couple of custom form fields for them.

However, my custom form fields are not playing nice with the validation in the sense that they get another id than what the validator expects. I don't know how or why they get the id that they do, I've tried digging for it but I haven't been able to find it.

The id on the form field container becomes CostEditableCostCheckbox with a number appended. The validator expects the id to be EditableCostCheckbox with the number appended. I have no idea why it does like this.

I have attached the relevant class. I am running SilverStripe 2.3.2.