hi everyone.
i am working on easy reservation calendar plugins for K2.
i have problem with plugins multi fields data.
i just create 4 field startDay,endDay,satatus,note
my data must be like that:
$reservation=array(
array("sDate"=>"04-03-2012","eDate"=>"29-04-2012","status"=>"r","note"=>"reserved by x"),
array("sDate"=>"05-05-2012","eDate"=>"11-05-2012","status"=>"b","note"=>"booked by y"),
array("sDate"=>"26-06-2012","eDate"=>"29-06-2012","status"=>"b","note"=>"reserved by z"),
array("sDate"=>"26-07-2012","eDate"=>"29-08-2012","status"=>"b","note"=>"reserved by t"),
);
and at the backend i am creating fields by javascript
name of field names are
startDay=plugins[k2reservationStartDay];
EndDay=plugins[k2reservationEndDay];
status=plugins[k2reservationStatus];
note=plugins[k2reservationNote];
i can add one data like that to database
{"k2reservationitemCalendarWidth":"800","k2reservationitemShowMonths":"8","k2reservationStartDay":"04-03-2012","k2reservationEndDay":"29-04-2012","k2reservationStatus":"b","k2reservationNote":"reserved by x"}
but i should add like array in array;
{"k2reservationitemCalendarWidth":"800","k2reservationitemShowMonths":"8","k2reservationStartDay":"04-03-2012,05-05-2012,26-06-2012,26-07-2012","k2reservationEndDay":"29-04-2012,11-05-2012,29-06-2012,29-08-2012","k2reservationStatus":"r,b,b,b","k2reservationNote":"reserved by x,booked by y,reserved by z,reserved by t"}
i am not good with json so i am looking for solitions.
Thank You.