By tristanmatthews on
Hi all,
I'm trying to figure out a good way to calculate (and set) a lot of defaults for CCK fields, but I'm a little confused about the relation between the admin section and the hook system.
Here is what I have done.
Defined my content type with a custom module
Added CCK fields to it through the admin section
Should I now add hooks to the custom module that relate to the CCK fields I have added?
Run my code to calculate my defaults as a preprocess function, and then figure out how to pass them through to the Admin manage fields defaults code section?
Something totally different that I have ruled out/not thought of because I evidently don't know what I'm doing?
Thanks,
Tristan
Comments
_
Maybe I'm not understanding you-- but if you've added the fields through the UI, why not set the defaults there as well?
So I want set the defaults
So I want set the defaults for about 10 fields, that will all have values calculated off of a view. I can't figure out a way to do it through the UI default that doesn't involve calling the view 10 times.