if( !empty($custom_fields) ) {
$output="";
foreach( $custom_fields as $key => $value ){
foreach( $value as $val ){
$output .= "{".$key." : '".$val."'},";
}
}
echo $output;
}
if( !empty($custom_fields) ) {
$output="";
foreach( $custom_fields as $key => $value ){
foreach( $value as $val ){
$output .= "{".$key." : '".$val."'},";
}
}
echo $output;
}