error when I'm trying to add an array to a select attribute
Permalink
Hi All,
I'm trying to set a select attribute with an array (in this case $genres):
But when I do this, I get the following issue:
Any ideas of what I can do?
I'm trying to set a select attribute with an array (in this case $genres):
$newPage->setAttribute('main_entry_music_genres', $genres);
But when I do this, I get the following issue:
Any ideas of what I can do?
bump
Have you seen this post? It might help you:http://www.concrete5.org/developers/bugs/5-6-2-1/setattribute-only-...
I have indeed seen that post as it was myself that made it :)
Turn out I was being an idiot, I was trying to pass an array with multiple arrays in it. Was getting some info from an API and for some reason didn't notice that the data was like that. Oops.
Turn out I was being an idiot, I was trying to pass an array with multiple arrays in it. Was getting some info from an API and for some reason didn't notice that the data was like that. Oops.
Haha, ok. Glad you solved it ;)