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've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

Form Questions /

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

datafieldbyname in docs but depreciated


Go to End


1038 Views

Avatar
okotoker

Community Member, 50 Posts

15 October 2012 at 6:51am

I am using a custom form template and as in 2.4 I am using datafieldbyname. Which works but gives a depreciated notice. Its telling me to use fields or fieldlist api. Which is fine, but the api also tells you to use dataFieldByName and this is included in the regular docs as well. I have tried all kinds of things without luck.

So if I want to use individual fields and not loop over them, what is the correct way to do this is SS3? As I said the docs seem to be out of date?