Marc Posted September 20, 2016 Posted September 20, 2016 I have a bunch of fields that have a label that is overwritten by the context of the template the fields belong to. So outside of the template these field have a different label from inside the template. I want to keep the outside label intact and overwrite the template-specific labels with the API. So how would I turn the code below into something that sets a new label for only the template context? $f->set("label", "new value"); $f->save();
LostKobrakai Posted September 20, 2016 Posted September 20, 2016 $fieldgroup = $template->fieldgroup; $f = $fieldgroup->getField($fieldName, true); // Do stuff $fields->saveFieldgroupContext($f, $fieldgroup); 7
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now