FuF Posted April 25, 2020 Share Posted April 25, 2020 Hi there, i have a ProFields Repeater Matrix called "Empfaenger" - with two fields "vorname" & "nachname" and for the Item headers {vorname} {nachname} set. When i create a new "Empfaenger" via the Backend - ist correctly shows me the values of the two fields "vorname" & "nachname". But when i create a new "Empfaenger" via the API : $empfaenger = $page->empfaenger->getNew(); $empfaenger->vorname = "Hulk"; $empfaenger->nachname = "Hogan"; $page->save(); The Item header is something like 1. None/undefined ᛫ Showing fields for all types... See attached screenshot. Why ist that? And how can i avoid this? Thanks & Cheers Simon Link to comment Share on other sites More sharing options...
FuF Posted April 26, 2020 Author Share Posted April 26, 2020 Okay i managed to solve the Problem. I found this thread and modified my code: $empfaenger = $page->empfaenger->getNew(); $empfaenger->repeater_matrix_type = 1; $empfaenger->vorname = "Hulk"; $empfaenger->nachname = "Hogan"; $page->save(); Defining the repeater_matrix_type did the trick! Cheers Simon Link to comment Share on other sites More sharing options...
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