get data from K2 database

Raimis 27 Aug, 2015
Hi,

k2 in database table "items" have row extra_fields and there is data like this:

[{"id":"4","value":"TEXT"},{"id":"5","value":"TEXT"},{"id":"6","value":"TEXT"},{"id":"7","value":["TEXT","","same"]},{"id":"8","value":"TEXT"}]

how can get info like array ? or posible in chronoform ?
GreyHead 27 Aug, 2015
Hi Raimis,

That is JSON encoded data - you can convert it to an array using PHP in a Custom code action
<?php
$form->data['some_name'] = json_decode($form->data['some_other_name'], false);
?>

Bob
This topic is locked and no more replies can be posted.