Home › Forums › Quform WordPress › Save to Database › Reply To: Save to Database
March 9, 2021 at 4:25 pm #32631
linux
Participant
Try to use code below. But still not save to database
//SAVE TO DATABASE
add_filter(‘quform_post_process_1’, function (array $result, Quform_Form $form) {
global $wpdb;
$data = array(
‘nama’ => $form->getValueText(‘quform_1_3′),
’email’ => $form->getValueText(‘quform_1_4’),
‘telepon’ => $form->getValueText(‘quform_1_5’),
‘pelatihan’ => $form->getValueText(‘quform_1_6’),
);
$wpdb->insert(‘pelatihan’, $data);
return $result;
}, 10, 2);