Create pod fields programatically
-
Hi
I’m trying to create a new field for a pod called “software” like this:$params = array( 'pod' => 'software', 'name' => 'myNewField', 'label' => 'myNewLabel', 'type' => 'text', ); $software = pods('software'); $new_field = $software->save_field ( $params, true, true, $db = true );
I don’t know what i’m doing wrong but $new_field just returns NULL.
Any help appreciated.
Cheers
Bonsak
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Create pod fields programatically’ is closed to new replies.